diff options
Diffstat (limited to 'utils/nsoption.c')
-rw-r--r-- | utils/nsoption.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/utils/nsoption.c b/utils/nsoption.c index ccdd23ae9..c83f7799a 100644 --- a/utils/nsoption.c +++ b/utils/nsoption.c @@ -734,8 +734,10 @@ nsoption_commandline(int *pargc, char **argv, struct nsoption_s *opts) /* check we have an option */ /* option must start -- and be as long as the shortest option*/ - if ((arglen < (2+5) ) || (arg[0] != '-') || (arg[1] != '-')) - break; + if ((arglen < (2+5) ) || (arg[0] != '-') || (arg[1] != '-')) { + idx++; + continue; + } arg += 2; /* skip -- */ |