summaryrefslogtreecommitdiff
path: root/vtysh/vtysh_user.c
diff options
context:
space:
mode:
Diffstat (limited to 'vtysh/vtysh_user.c')
-rw-r--r--vtysh/vtysh_user.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/vtysh/vtysh_user.c b/vtysh/vtysh_user.c
index 1886ba3a67..b1ba1a24ae 100644
--- a/vtysh/vtysh_user.c
+++ b/vtysh/vtysh_user.c
@@ -173,7 +173,8 @@ DEFUN (banner_motd_file,
"Banner from a file\n"
"Filename\n")
{
- return cmd_banner_motd_file (argv[0]);
+ int idx_file = 3;
+ return cmd_banner_motd_file (argv[idx_file]->arg);
}
DEFUN (username_nopassword,
@@ -183,8 +184,9 @@ DEFUN (username_nopassword,
"\n"
"\n")
{
+ int idx_word = 1;
struct vtysh_user *user;
- user = user_get (argv[0]);
+ user = user_get (argv[idx_word]->arg);
user->nopassword = 1;
return CMD_SUCCESS;
}