From 835ad3a984c5590ae4f6c94f2f0781ea049d1ae8 Mon Sep 17 00:00:00 2001 From: Kaarle Ritvanen Date: Wed, 12 Apr 2017 00:58:46 +0300 Subject: libbb: GETOPT_RESET macro Signed-off-by: Kaarle Ritvanen Signed-off-by: Denys Vlasenko --- runit/sv.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'runit') diff --git a/runit/sv.c b/runit/sv.c index 9e2132259..64f1ae395 100644 --- a/runit/sv.c +++ b/runit/sv.c @@ -688,12 +688,7 @@ int svc_main(int argc UNUSED_PARAM, char **argv) /* getopt32() was already called: * reset the libc getopt() function, which keeps internal state. */ -#ifdef __GLIBC__ - optind = 0; -#else /* BSD style */ - optind = 1; - /* optreset = 1; */ -#endif + GETOPT_RESET(); do { if (opts & 1) { -- cgit v1.2.3