aboutsummaryrefslogtreecommitdiff
path: root/libbb/getopt32.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2017-07-03 21:31:16 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2017-07-03 21:31:16 +0200
commitd4e4fdb5ce5ccc067b3d35d877f7a7d978869517 (patch)
treebac3e4a55fa72db0c67d377b90869b4d63e8c3c9 /libbb/getopt32.c
parent2e989ef232e35750df573898077dd356003705b2 (diff)
downloadbusybox-w32-d4e4fdb5ce5ccc067b3d35d877f7a7d978869517.tar.gz
busybox-w32-d4e4fdb5ce5ccc067b3d35d877f7a7d978869517.tar.bz2
busybox-w32-d4e4fdb5ce5ccc067b3d35d877f7a7d978869517.zip
fixes for bugs found by make_single_applets.sh
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'libbb/getopt32.c')
-rw-r--r--libbb/getopt32.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/libbb/getopt32.c b/libbb/getopt32.c
index b87b83538..80f4cc060 100644
--- a/libbb/getopt32.c
+++ b/libbb/getopt32.c
@@ -379,9 +379,7 @@ getopt32(char **argv, const char *applet_opts, ...)
379 int spec_flgs = 0; 379 int spec_flgs = 0;
380 380
381 /* skip 0: some applets cheat: they do not actually HAVE argv[0] */ 381 /* skip 0: some applets cheat: they do not actually HAVE argv[0] */
382 argc = 1; 382 argc = 1 + string_array_len(argv + 1);
383 while (argv[argc])
384 argc++;
385 383
386 va_start(p, applet_opts); 384 va_start(p, applet_opts);
387 385