libbb: GETOPT_RESET macro
Signed-off-by: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
diff --git a/runit/sv.c b/runit/sv.c
index 9e21322..64f1ae3 100644
--- a/runit/sv.c
+++ b/runit/sv.c
@@ -688,12 +688,7 @@
/* 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) {