summaryrefslogtreecommitdiff
path: root/lib/if.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/if.c')
-rw-r--r--lib/if.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/if.c b/lib/if.c
index 0fe7da1c0d..8e6a9a6968 100644
--- a/lib/if.c
+++ b/lib/if.c
@@ -663,8 +663,9 @@ DEFUN_NOSH (no_interface,
"Interface's name\n"
VRF_CMD_HELP_STR)
{
+ int idx_vrf = 4;
const char *ifname = argv[2]->arg;
- const char *vrfname = (argc > 3) ? argv[3]->arg : NULL;
+ const char *vrfname = (argc > 3) ? argv[idx_vrf]->arg : NULL;
// deleting interface
struct interface *ifp;