diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2016-03-17 16:12:55 -0400 |
|---|---|---|
| committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2016-03-17 16:12:55 -0400 |
| commit | 73d2dad0bd736b6bfd668a1de2a8f26baf2c5cdc (patch) | |
| tree | fd729eb592114f8e30c6efc404ff297df87a0639 /lib/command.c | |
| parent | c5344534ff71e026b29c6905c9737e658efdd515 (diff) | |
lib: Fix assert in node_parent()
With this sequence of commands in a conf file:
router bgp X
address-family ipv4
exit
address-family ipv6
exit
When the bgp AS # is currently configured as !X and the
'vtysh -b -f <conf file above>' command run, vtysh will
crash with an assert.
This commit fixes that issue.
Ticket: CM-9852
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Reviewed-by: Daniel Walton <dwalton@cumulusnetworks.com>
Diffstat (limited to 'lib/command.c')
| -rw-r--r-- | lib/command.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/command.c b/lib/command.c index 16f53da3ab..05fc9b9e27 100644 --- a/lib/command.c +++ b/lib/command.c @@ -2819,7 +2819,7 @@ command_config_read_one_line (struct vty *vty, struct cmd_element **cmd, int use !(!use_daemon && ret == CMD_ERR_NOTHING_TODO) && ret != CMD_SUCCESS && ret != CMD_WARNING && - vty->node != CONFIG_NODE) { + vty->node > CONFIG_NODE) { vty->node = node_parent(vty->node); ret = cmd_execute_command_strict (vline, vty, cmd); } |
