diff options
author | Renato Westphal <renato@opensourcerouting.org> | 2017-09-12 14:52:20 +0200 |
---|---|---|
committer | Renato Westphal <renato@opensourcerouting.org> | 2017-09-12 16:10:15 +0200 |
commit | 08e4b244515682d2adb779a429615034f4956262 (patch) | |
tree | 30b9a7625c3b4b284f4bbb4777bf1b2b3b19d4e8 /ldpd/ldp_debug.c | |
parent | ldpd: fix broken label allocation (diff) | |
download | frr-08e4b244515682d2adb779a429615034f4956262.tar.xz frr-08e4b244515682d2adb779a429615034f4956262.zip |
ldpd: guard the label allocation debug messages
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'ldpd/ldp_debug.c')
-rw-r--r-- | ldpd/ldp_debug.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/ldpd/ldp_debug.c b/ldpd/ldp_debug.c index d80ec8dfb..ee4f0843b 100644 --- a/ldpd/ldp_debug.c +++ b/ldpd/ldp_debug.c @@ -66,6 +66,11 @@ ldp_vty_debug(struct vty *vty, const char *negate, const char *type_str, DEBUG_OFF(event, EVENT); else DEBUG_ON(event, EVENT); + } else if (strcmp(type_str, "labels") == 0) { + if (negate) + DEBUG_OFF(labels, LABELS); + else + DEBUG_ON(labels, LABELS); } else if (strcmp(type_str, "messages") == 0) { if (dir_str == NULL) return (CMD_WARNING_CONFIG_FAILED); @@ -115,6 +120,8 @@ ldp_vty_show_debugging(struct vty *vty) vty_out (vty, " LDP errors debugging is on\n"); if (LDP_DEBUG(event, EVENT)) vty_out (vty, " LDP events debugging is on\n"); + if (LDP_DEBUG(labels, LABELS)) + vty_out (vty, " LDP labels debugging is on\n"); if (LDP_DEBUG(msg, MSG_RECV_ALL)) vty_out (vty, " LDP detailed messages debugging is on (inbound)\n"); @@ -157,6 +164,11 @@ ldp_debug_config_write(struct vty *vty) write = 1; } + if (CONF_LDP_DEBUG(labels, LABELS)) { + vty_out (vty, "debug mpls ldp labels\n"); + write = 1; + } + if (CONF_LDP_DEBUG(msg, MSG_RECV_ALL)) { vty_out (vty, "debug mpls ldp messages recv all\n"); write = 1; |