summaryrefslogtreecommitdiffstats
path: root/bgpd/bgp_debug.c
diff options
context:
space:
mode:
authorDaniel Walton <dwalton@cumulusnetworks.com>2017-09-20 17:12:17 +0200
committerDaniel Walton <dwalton@cumulusnetworks.com>2017-09-20 17:12:17 +0200
commitffd71765f15ade1f724ac41165a1ce5269f871ae (patch)
treee6a196d912873f99361a3b4b77872b8af6a150f1 /bgpd/bgp_debug.c
parentzebra: return CMD_SUCCESS when enabling debugs (diff)
downloadfrr-ffd71765f15ade1f724ac41165a1ce5269f871ae.tar.xz
frr-ffd71765f15ade1f724ac41165a1ce5269f871ae.zip
bgpd: change debug_bgp_bestpath_prefix to DEFUN
Diffstat (limited to 'bgpd/bgp_debug.c')
-rw-r--r--bgpd/bgp_debug.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/bgpd/bgp_debug.c b/bgpd/bgp_debug.c
index e4ebb6af2..36ac73ae0 100644
--- a/bgpd/bgp_debug.c
+++ b/bgpd/bgp_debug.c
@@ -870,9 +870,9 @@ DEFUN (no_debug_bgp_keepalive_peer,
#endif
/* debug bgp bestpath */
-DEFPY (debug_bgp_bestpath_prefix,
+DEFUN (debug_bgp_bestpath_prefix,
debug_bgp_bestpath_prefix_cmd,
- "debug bgp bestpath <A.B.C.D/M|X:X::X:X/M>$bestpath",
+ "debug bgp bestpath <A.B.C.D/M|X:X::X:X/M>",
DEBUG_STR
BGP_STR
"BGP bestpath\n"
@@ -883,28 +883,28 @@ DEFPY (debug_bgp_bestpath_prefix,
int idx_ipv4_ipv6_prefixlen = 3;
argv_p = prefix_new();
- str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
+ (void)str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
apply_mask(argv_p);
if (!bgp_debug_bestpath_prefixes)
bgp_debug_bestpath_prefixes = list_new();
if (bgp_debug_list_has_entry(bgp_debug_bestpath_prefixes, NULL,
- bestpath)) {
+ argv_p)) {
vty_out(vty,
"BGP bestpath debugging is already enabled for %s\n",
- bestpath_str);
+ argv[idx_ipv4_ipv6_prefixlen]->arg);
return CMD_SUCCESS;
}
- bgp_debug_list_add_entry(bgp_debug_bestpath_prefixes, NULL, bestpath);
+ bgp_debug_list_add_entry(bgp_debug_bestpath_prefixes, NULL, argv_p);
if (vty->node == CONFIG_NODE) {
DEBUG_ON(bestpath, BESTPATH);
} else {
TERM_DEBUG_ON(bestpath, BESTPATH);
vty_out(vty, "BGP bestpath debugging is on for %s\n",
- bestpath_str);
+ argv[idx_ipv4_ipv6_prefixlen]->arg);
}
return CMD_SUCCESS;
@@ -925,7 +925,7 @@ DEFUN (no_debug_bgp_bestpath_prefix,
int found_prefix = 0;
argv_p = prefix_new();
- str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
+ (void)str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
apply_mask(argv_p);
if (bgp_debug_bestpath_prefixes
@@ -1271,7 +1271,7 @@ DEFUN (debug_bgp_update_prefix,
struct prefix *argv_p;
argv_p = prefix_new();
- str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
+ (void)str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
apply_mask(argv_p);
if (!bgp_debug_update_prefixes)
@@ -1313,7 +1313,7 @@ DEFUN (no_debug_bgp_update_prefix,
int found_prefix = 0;
argv_p = prefix_new();
- str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
+ (void)str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
apply_mask(argv_p);
if (bgp_debug_update_prefixes
@@ -1404,7 +1404,7 @@ DEFUN (debug_bgp_zebra_prefix,
struct prefix *argv_p;
argv_p = prefix_new();
- str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
+ (void)str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
apply_mask(argv_p);
if (!bgp_debug_zebra_prefixes)
@@ -1464,7 +1464,7 @@ DEFUN (no_debug_bgp_zebra_prefix,
int found_prefix = 0;
argv_p = prefix_new();
- str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
+ (void)str2prefix(argv[idx_ipv4_ipv6_prefixlen]->arg, argv_p);
apply_mask(argv_p);
if (bgp_debug_zebra_prefixes