diff options
author | Eric Andersen <andersen@codepoet.org> | 1999-10-13 22:01:10 +0400 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 1999-10-13 22:01:10 +0400 |
commit | c6cb79dedfb1af4ce64e75cd1c0d3cc1bfa71225 (patch) | |
tree | 685c18e7a6e52b315c9b8a142b8b21fc55e635fc /applets | |
parent | 5de3065f5870526a68adee314fe181af976a9246 (diff) |
More stuff
Diffstat (limited to 'applets')
-rw-r--r-- | applets/busybox.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/applets/busybox.c b/applets/busybox.c index f0258c36e..0892e84ec 100644 --- a/applets/busybox.c +++ b/applets/busybox.c @@ -199,12 +199,7 @@ int busybox_main(int argc, char **argv) argc--; argv++; - /* If we've already been here once, exit now */ - if (been_there_done_that == 1) - return -1; - been_there_done_that = 1; - - if (argc < 1) { + if (been_there_done_that == 1 || argc < 1) { const struct Applet *a = applets; fprintf(stderr, "BusyBox v%s (%s) multi-call binary -- GPL2\n", BB_VER, BB_BT); @@ -224,6 +219,9 @@ int busybox_main(int argc, char **argv) } fprintf(stderr, "\n\n"); exit(-1); - } else + } else { + /* If we've already been here once, exit now */ + been_there_done_that = 1; return (main(argc, argv)); + } } |