]> git.puffer.fish Git - matthieu/frr.git/commitdiff
vtysh: Allow `service ...` lines to not repeat
authorDonald Sharp <sharpd@nvidia.com>
Thu, 3 Nov 2022 16:59:01 +0000 (12:59 -0400)
committerDonald Sharp <sharpd@nvidia.com>
Thu, 3 Nov 2022 17:01:35 +0000 (13:01 -0400)
When any `service ...` line is entered and there are multiple
daemons running prevent this from being displayed multiple times.

Fixes: #5475
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
vtysh/vtysh_config.c

index 0f28b49f72474e401ee325f623c1af7086b32bf2..1ebc84b35681dad74a687f1c38c36ceac54c00ac 100644 (file)
@@ -492,8 +492,8 @@ void vtysh_config_parse_line(void *arg, const char *line)
                                    strlen("no ip prefix-list")) == 0 ||
                            strncmp(line, "no ipv6 prefix-list",
                                    strlen("no ipv6 prefix-list")) == 0 ||
-                           strncmp(line, "service cputime-stats",
-                                   strlen("service cputime-stats")) == 0 ||
+                           strncmp(line, "service ", strlen("service ")) ==
+                                   0 ||
                            strncmp(line, "no service cputime-stats",
                                    strlen("no service cputime-stats")) == 0 ||
                            strncmp(line, "service cputime-warning",