aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2021-05-14 09:21:04 +0100
committerRon Yorston <rmy@pobox.com>2021-05-14 09:21:04 +0100
commitaf35e7ec1963da7ad2e66ecb0e2c8398099bde5c (patch)
tree963e904cb8f9ba63408c04c2a49390b4b108fce8
parente5b7d2b2c17b1bd80d759350bb6d3cfa1303f687 (diff)
downloadbusybox-w32-af35e7ec1963da7ad2e66ecb0e2c8398099bde5c.tar.gz
busybox-w32-af35e7ec1963da7ad2e66ecb0e2c8398099bde5c.tar.bz2
busybox-w32-af35e7ec1963da7ad2e66ecb0e2c8398099bde5c.zip
busybox: make 'busybox --help busybox' work
Upstream changes broke the 'busybox --help busybox' command. Fix it.
-rw-r--r--libbb/appletlib.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libbb/appletlib.c b/libbb/appletlib.c
index f53d74834..8f8275831 100644
--- a/libbb/appletlib.c
+++ b/libbb/appletlib.c
@@ -1025,6 +1025,10 @@ int busybox_main(int argc UNUSED_PARAM, char **argv)
1025 /* "busybox --help [<applet>]" */ 1025 /* "busybox --help [<applet>]" */
1026 if (!argv[2]) 1026 if (!argv[2])
1027 goto help; 1027 goto help;
1028#if ENABLE_PLATFORM_MINGW32
1029 if (strcmp(argv[2], "busybox") == 0)
1030 goto help;
1031#endif
1028 /* convert to "<applet> --help" */ 1032 /* convert to "<applet> --help" */
1029 applet_name = argv[0] = argv[2]; 1033 applet_name = argv[0] = argv[2];
1030 argv[2] = NULL; 1034 argv[2] = NULL;