From dd79e1d4d3b9725e927d1c26e0d3fdb49e29ba9c Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Tue, 30 Aug 2022 17:12:34 +0200 Subject: [PATCH] fix [ --help ] and [[ --help ]] function old new delta show_usage_if_dash_dash_help 72 79 +7 Signed-off-by: Denys Vlasenko --- libbb/appletlib.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libbb/appletlib.c b/libbb/appletlib.c index 9b9d7dbd6..d5335d353 100644 --- a/libbb/appletlib.c +++ b/libbb/appletlib.c @@ -937,6 +937,9 @@ void FAST_FUNC show_usage_if_dash_dash_help(int applet_no, char **argv) # endif # if defined APPLET_NO_echo && applet_no != APPLET_NO_echo +# endif +# if ENABLE_TEST1 || ENABLE_TEST2 + && argv[0][0] != '[' /* exclude [ --help ] and [[ --help ]] too */ # endif ) { if (argv[1] && strcmp(argv[1], "--help") == 0) {