diff options
Diffstat (limited to 'busybox.c')
-rw-r--r-- | busybox.c | 12 |
1 files changed, 5 insertions, 7 deletions
@@ -199,12 +199,7 @@ int busybox_main(int argc, char **argv) | |||
199 | argc--; | 199 | argc--; |
200 | argv++; | 200 | argv++; |
201 | 201 | ||
202 | /* If we've already been here once, exit now */ | 202 | if (been_there_done_that == 1 || argc < 1) { |
203 | if (been_there_done_that == 1) | ||
204 | return -1; | ||
205 | been_there_done_that = 1; | ||
206 | |||
207 | if (argc < 1) { | ||
208 | const struct Applet *a = applets; | 203 | const struct Applet *a = applets; |
209 | fprintf(stderr, "BusyBox v%s (%s) multi-call binary -- GPL2\n", | 204 | fprintf(stderr, "BusyBox v%s (%s) multi-call binary -- GPL2\n", |
210 | BB_VER, BB_BT); | 205 | BB_VER, BB_BT); |
@@ -224,6 +219,9 @@ int busybox_main(int argc, char **argv) | |||
224 | } | 219 | } |
225 | fprintf(stderr, "\n\n"); | 220 | fprintf(stderr, "\n\n"); |
226 | exit(-1); | 221 | exit(-1); |
227 | } else | 222 | } else { |
223 | /* If we've already been here once, exit now */ | ||
224 | been_there_done_that = 1; | ||
228 | return (main(argc, argv)); | 225 | return (main(argc, argv)); |
226 | } | ||
229 | } | 227 | } |