diff options
author | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-06-18 15:13:37 +0200 |
---|---|---|
committer | Quentin Young <qlyoung@cumulusnetworks.com> | 2018-08-14 22:02:05 +0200 |
commit | 472878dc0fdd5e17500e8a6ba8a65d13e36d9467 (patch) | |
tree | e92ddabd91c15d6b465e577d09216c3207ed907e /lib/log.c | |
parent | lib: Add LIB_ERR_NS to error subsystem (diff) | |
download | frr-472878dc0fdd5e17500e8a6ba8a65d13e36d9467.tar.xz frr-472878dc0fdd5e17500e8a6ba8a65d13e36d9467.zip |
lib: Add LIB_ERR_DEVELOPMENT
Sometimes a error state is detected when we have added
new code to FRR, but not updated all the places that
we should have. Consider this a developmental escape
that needs to be fixed.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'lib/log.c')
-rw-r--r-- | lib/log.c | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -987,7 +987,8 @@ static const struct zebra_desc_table *zroute_lookup(unsigned int zroute) unsigned int i; if (zroute >= array_size(route_types)) { - zlog_err("unknown zebra route type: %u", zroute); + zlog_ferr(LIB_ERR_DEVELOPMENT, "unknown zebra route type: %u", + zroute); return &unknown; } if (zroute == route_types[zroute].type) @@ -1001,7 +1002,9 @@ static const struct zebra_desc_table *zroute_lookup(unsigned int zroute) return &route_types[i]; } } - zlog_err("internal error: cannot find route type %u in table!", zroute); + zlog_ferr(LIB_ERR_DEVELOPMENT, + "internal error: cannot find route type %u in table!", + zroute); return &unknown; } @@ -1018,7 +1021,8 @@ char zebra_route_char(unsigned int zroute) const char *zserv_command_string(unsigned int command) { if (command >= array_size(command_types)) { - zlog_err("unknown zserv command type: %u", command); + zlog_ferr(LIB_ERR_DEVELOPMENT, "unknown zserv command type: %u", + command); return unknown.string; } return command_types[command].string; |