]> granicus.if.org Git - postgresql/commitdiff
Fix for "--" options. Allow --xxx as a valid flag, from NetBSD fix.
authorBruce Momjian <bruce@momjian.us>
Mon, 26 Nov 2001 19:30:58 +0000 (19:30 +0000)
committerBruce Momjian <bruce@momjian.us>
Mon, 26 Nov 2001 19:30:58 +0000 (19:30 +0000)
src/utils/getopt.c

index 442631347c5699465de33378b7959312865653a3..bbe81c1699017c127d796486f30b30e47eba77da 100644 (file)
@@ -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;