From ba372620c256b23340c5630098f1a81c10022386 Mon Sep 17 00:00:00 2001 From: Eric Andersen Date: Tue, 20 Mar 2001 17:39:53 +0000 Subject: Force applet_name to be "sh" when command prefaced by "-" --- applets/busybox.c | 2 +- busybox.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/applets/busybox.c b/applets/busybox.c index 2872f1e..03a2525 100644 --- a/applets/busybox.c +++ b/applets/busybox.c @@ -93,7 +93,7 @@ int main(int argc, char **argv) /* Add in a special case hack -- whenever **argv == '-' * (i.e. '-su' or '-sh') always invoke the shell */ if (**argv == '-' && *(*argv+1)!= '-') { - exit(((*(shell_main)) (argc, argv))); + applet_name = "sh"; } #endif diff --git a/busybox.c b/busybox.c index 2872f1e..03a2525 100644 --- a/busybox.c +++ b/busybox.c @@ -93,7 +93,7 @@ int main(int argc, char **argv) /* Add in a special case hack -- whenever **argv == '-' * (i.e. '-su' or '-sh') always invoke the shell */ if (**argv == '-' && *(*argv+1)!= '-') { - exit(((*(shell_main)) (argc, argv))); + applet_name = "sh"; } #endif -- cgit v1.1