summaryrefslogtreecommitdiff
path: root/pimd/pim_cmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'pimd/pim_cmd.c')
-rw-r--r--pimd/pim_cmd.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/pimd/pim_cmd.c b/pimd/pim_cmd.c
index d5dbe4f7ab..80decc34cd 100644
--- a/pimd/pim_cmd.c
+++ b/pimd/pim_cmd.c
@@ -5075,11 +5075,16 @@ DEFUN (interface_ip_pim_hello,
pim_ifp = ifp->info;
- if (!pim_ifp) {
- vty_out(vty, "Pim not enabled on this interface%s", VTY_NEWLINE);
- return CMD_WARNING;
- }
+ if (!pim_ifp)
+ {
+ if (!pim_cmd_interface_add(ifp))
+ {
+ vty_out(vty, "Could not enable PIM SM on interface%s", VTY_NEWLINE);
+ return CMD_WARNING;
+ }
+ }
+ pim_ifp = ifp->info;
pim_ifp->pim_hello_period = strtol(argv[idx_time]->arg, NULL, 10);
if (argc == idx_hold + 1)