From af35e7ec1963da7ad2e66ecb0e2c8398099bde5c Mon Sep 17 00:00:00 2001
From: Ron Yorston <rmy@pobox.com>
Date: Fri, 14 May 2021 09:21:04 +0100
Subject: busybox: make 'busybox --help busybox' work

Upstream changes broke the 'busybox --help busybox' command.
Fix it.
---
 libbb/appletlib.c | 4 ++++
 1 file changed, 4 insertions(+)

(limited to 'libbb')

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)
 		/* "busybox --help [<applet>]" */
 		if (!argv[2])
 			goto help;
+#if ENABLE_PLATFORM_MINGW32
+		if (strcmp(argv[2], "busybox") == 0)
+			goto help;
+#endif
 		/* convert to "<applet> --help" */
 		applet_name = argv[0] = argv[2];
 		argv[2] = NULL;
-- 
cgit v1.2.3-55-g6feb