summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cfgparser.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cfgparser.c b/cfgparser.c
index e20c831492..8c9912b0cd 100644
--- a/cfgparser.c
+++ b/cfgparser.c
@@ -522,7 +522,7 @@ int parse_command_line(struct config *conf, int argc, char **argv, char **envp,
for (i = 1; i < argc; i++) {
next:
opt = argv[i];
- /* check for -- (no more options id.) except --help ! */
+ /* check for -- (no more options id.) except --help! */
if ((*opt == '-') && (*(opt+1) == '-') && (*(opt+2) != 'h'))
{
no_more_opts = 1;
@@ -535,7 +535,7 @@ next:
goto next;
}
- if ((no_more_opts == 0) && (*opt == '-')) /* option */
+ if ((no_more_opts == 0) && (*opt == '-') && (*(opt+1) != 0)) /* option */
{
/* remove trailing '-' */
opt++;