From b45d8ccc3280677dae5dda773f158a4b3c5e597e Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Wed, 24 Oct 2018 21:03:18 -0400 Subject: [PATCH] lib: If command was successful don't store the command as an error The CMD_SUCCESS_DAEMON case should be excluded from storing the command line that we think failed. Signed-off-by: Donald Sharp --- lib/command.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/command.c b/lib/command.c index 839c37b102..127e1a0a0a 100644 --- a/lib/command.c +++ b/lib/command.c @@ -1323,7 +1323,9 @@ int command_config_read_one_line(struct vty *vty, } } - if (ret != CMD_SUCCESS && ret != CMD_WARNING) { + if (ret != CMD_SUCCESS && + ret != CMD_WARNING && + ret != CMD_SUCCESS_DAEMON) { struct vty_error *ve = XCALLOC(MTYPE_TMP, sizeof(*ve)); memcpy(ve->error_buf, vty->buf, VTY_BUFSIZ); -- 2.39.5