summaryrefslogtreecommitdiffstats
path: root/lib/command_parse.y
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2018-06-19 22:28:45 +0200
committerQuentin Young <qlyoung@cumulusnetworks.com>2018-08-14 22:02:05 +0200
commitb87478cb3e18e9557ebd95fb3a39e28b6f2d4f62 (patch)
tree502aef41c0202a08804956ea66a8086f68c6e723 /lib/command_parse.y
parentlib: Remove unnecessary zebra.h include (diff)
downloadfrr-b87478cb3e18e9557ebd95fb3a39e28b6f2d4f62.tar.xz
frr-b87478cb3e18e9557ebd95fb3a39e28b6f2d4f62.zip
lib: Convert zlog_err for clippy build
The clippy code does not need to log the error messages as errors as that it is only run as part of the build itself and as long as we see the notifications we are good. So convert zlog_err to zlog_notice so that we do not think we have any zlog_err's in lib anymore Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to '')
-rw-r--r--lib/command_parse.y8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/command_parse.y b/lib/command_parse.y
index 0f3e42219..1b304a98b 100644
--- a/lib/command_parse.y
+++ b/lib/command_parse.y
@@ -404,8 +404,8 @@ yyerror (CMD_YYLTYPE *loc, struct parser_ctx *ctx, char const *msg)
char spacing[256];
int lineno = 0;
- zlog_err ("%s: FATAL parse error: %s", __func__, msg);
- zlog_err ("%s: %d:%d-%d of this command definition:", __func__, loc->first_line, loc->first_column, loc->last_column);
+ zlog_notice ("%s: FATAL parse error: %s", __func__, msg);
+ zlog_notice ("%s: %d:%d-%d of this command definition:", __func__, loc->first_line, loc->first_column, loc->last_column);
line = tmpstr;
do {
@@ -414,7 +414,7 @@ yyerror (CMD_YYLTYPE *loc, struct parser_ctx *ctx, char const *msg)
if (eol)
*eol++ = '\0';
- zlog_err ("%s: | %s", __func__, line);
+ zlog_notice ("%s: | %s", __func__, line);
if (lineno == loc->first_line && lineno == loc->last_line
&& loc->first_column < (int)sizeof(spacing) - 1
&& loc->last_column < (int)sizeof(spacing) - 1) {
@@ -426,7 +426,7 @@ yyerror (CMD_YYLTYPE *loc, struct parser_ctx *ctx, char const *msg)
memset(spacing, ' ', loc->first_column - 1);
memset(spacing + loc->first_column - 1, '^', len);
spacing[loc->first_column - 1 + len] = '\0';
- zlog_err ("%s: | %s", __func__, spacing);
+ zlog_notice ("%s: | %s", __func__, spacing);
}
} while ((line = eol));
free(tmpstr);