From dab8cd005fae1fa33ef7203e85dd7ab93108f418 Mon Sep 17 00:00:00 2001 From: David Lamparter Date: Fri, 10 Feb 2017 16:56:10 +0100 Subject: [PATCH] *: fix ambiguous commands Some "show [ip] bgp ipv4 encap ..." commands remaining ambiguous. Signed-off-by: David Lamparter --- bgpd/bgp_vty.c | 2 +- ospf6d/ospf6_asbr.c | 8 ++++---- pimd/pim_cmd.c | 2 +- zebra/zebra_mpls_vty.c | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/bgpd/bgp_vty.c b/bgpd/bgp_vty.c index 01d1768691..b4425297b3 100644 --- a/bgpd/bgp_vty.c +++ b/bgpd/bgp_vty.c @@ -2841,7 +2841,7 @@ DEFUN (neighbor_peer_group, DEFUN (no_neighbor, no_neighbor_cmd, - "no neighbor [remote-as <(1-4294967295)|internal|external>]", + "no neighbor [remote-as <(1-4294967295)|internal|external>]>", NO_STR NEIGHBOR_STR NEIGHBOR_ADDR_STR2 diff --git a/ospf6d/ospf6_asbr.c b/ospf6d/ospf6_asbr.c index 643519e3fa..5f2d662b78 100644 --- a/ospf6d/ospf6_asbr.c +++ b/ospf6d/ospf6_asbr.c @@ -1114,7 +1114,7 @@ DEFUN (ospf6_routemap_set_metric_type, /* delete "set metric-type" */ DEFUN (ospf6_routemap_no_set_metric_type, ospf6_routemap_no_set_metric_type_cmd, - "no set metric-type ", + "no set metric-type []", NO_STR "Set value\n" "Type of metric\n" @@ -1122,9 +1122,9 @@ DEFUN (ospf6_routemap_no_set_metric_type, "OSPF6 external type 2 metric\n") { VTY_DECLVAR_CONTEXT(route_map_index, route_map_index); - int idx_external = 3; - int ret = route_map_delete_set (route_map_index, - "metric-type", argv[idx_external]->arg); + char *ext = (argc == 4) ? argv[3]->text : NULL; + int ret = route_map_delete_set (route_map_index, + "metric-type", ext); return route_map_command_status (vty, ret); } diff --git a/pimd/pim_cmd.c b/pimd/pim_cmd.c index ae23499d97..62d8ad8e07 100644 --- a/pimd/pim_cmd.c +++ b/pimd/pim_cmd.c @@ -5964,7 +5964,7 @@ ip_msdp_show_sa_sg(struct vty *vty, const char *src, const char *grp, u_char uj) DEFUN (show_ip_msdp_sa_sg, show_ip_msdp_sa_sg_cmd, - "show ip msdp sa [A.B.C.D] [A.B.C.D] [json]", + "show ip msdp sa [A.B.C.D [A.B.C.D]] [json]", SHOW_STR IP_STR MSDP_STR diff --git a/zebra/zebra_mpls_vty.c b/zebra/zebra_mpls_vty.c index fcd0fff32c..dd381723c5 100644 --- a/zebra/zebra_mpls_vty.c +++ b/zebra/zebra_mpls_vty.c @@ -472,7 +472,7 @@ DEFUN (no_ip_route_tag_distance_label, DEFUN (no_ip_route_mask_distance_label, no_ip_route_mask_distance_label_cmd, - "no ip route A.B.C.D A.B.C.D (1-255)", + "no ip route A.B.C.D A.B.C.D (1-255) label WORD", NO_STR IP_STR "Establish static routes\n" @@ -486,7 +486,7 @@ DEFUN (no_ip_route_mask_distance_label, "One or more labels separated by '/'\n") { return zebra_static_ipv4 (vty, SAFI_UNICAST, 0, argv[3]->arg, argv[4]->arg, argv[5]->arg, NULL, NULL, - argv[6]->arg, NULL, NULL); + argv[6]->arg, NULL, argv[8]->arg); } DEFUN (no_ip_route_mask_tag_distance_label, -- 2.39.5