summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruce Momjian2001-11-26 19:30:58 +0000
committerBruce Momjian2001-11-26 19:30:58 +0000
commitbbb74efd4db68248b7da10d02625d30558278b7e (patch)
tree38df86162417623f1d6ba465a7dfdb3eec6b90aa
parentbf434932f9cb380b88342a77bf6c5cda4c7011e8 (diff)
Fix for "--" options. Allow --xxx as a valid flag, from NetBSD fix.
-rw-r--r--src/utils/getopt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/utils/getopt.c b/src/utils/getopt.c
index 442631347c..bbe81c1699 100644
--- a/src/utils/getopt.c
+++ b/src/utils/getopt.c
@@ -71,7 +71,7 @@ const char *ostr;
place = EMSG;
return -1;
}
- if (place[1] && *++place == '-')
+ if (place[1] && *++place == '-' && place[1] == '\0')
{ /* found "--" */
++optind;
place = EMSG;