diff options
author | Rob Landley <rob@landley.net> | 2014-09-27 19:58:18 -0500 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2014-09-27 19:58:18 -0500 |
commit | dc1af185e73410c5cad997c600678c212262a13c (patch) | |
tree | 43b8dff99d6607f726dd47b56965779da8bc1128 /lib | |
parent | e0d8009d76b3a2451cb6c6ed2b241c7eff06ed60 (diff) | |
download | toybox-dc1af185e73410c5cad997c600678c212262a13c.tar.gz |
Don't segfault for --help of single.sh build of OLDTOY commands that use another command's help.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/help.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -25,6 +25,11 @@ void show_help(void) while (i--) s += strlen(s) + 1; // If it's an alias, restart search for real name if (*s != 255) break; + if (!CFG_TOYBOX) { + s = xmprintf("See %s --help\n", ++s); + + break; + } i = toy_find(++s)-toy_list; } |