Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.busybox.net/busybox.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/shell
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2017-07-07 20:08:56 +0300
committerDenys Vlasenko <vda.linux@googlemail.com>2017-07-18 20:20:58 +0300
commit54916641be96b6b13e3df9b09dd5a78abefb612b (patch)
tree72b69b752000bb262f97669f6d7b91b770b8f38b /shell
parent80cb8796f86754faa1569994b9355eeffe0b7759 (diff)
main: fix the case where user has "halt" as login shell. Closes 9986
halt::0:0::/:/sbin/halt function old new delta run_applet_and_exit 748 751 +3 run_applet_no_and_exit 467 459 -8 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'shell')
-rw-r--r--shell/ash.c2
-rw-r--r--shell/hush.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/shell/ash.c b/shell/ash.c
index 6d46e3719..2e1d1e7b7 100644
--- a/shell/ash.c
+++ b/shell/ash.c
@@ -7688,7 +7688,7 @@ tryexec(IF_FEATURE_SH_STANDALONE(int applet_no,) char *cmd, char **argv, char **
clearenv();
while (*envp)
putenv(*envp++);
- run_applet_no_and_exit(applet_no, argv);
+ run_applet_no_and_exit(applet_no, cmd, argv);
}
/* re-exec ourselves with the new arguments */
execve(bb_busybox_exec_path, argv, envp);
diff --git a/shell/hush.c b/shell/hush.c
index db8ca4f97..7cceab30d 100644
--- a/shell/hush.c
+++ b/shell/hush.c
@@ -7064,7 +7064,7 @@ static NOINLINE void pseudo_exec_argv(nommu_save_t *nommu_save,
/* Do not leak open fds from opened script files etc */
close_all_FILE_list();
debug_printf_exec("running applet '%s'\n", argv[0]);
- run_applet_no_and_exit(a, argv);
+ run_applet_no_and_exit(a, argv[0], argv);
}
# endif
/* Re-exec ourselves */