Fix -W with optional parameters in getopt.
commitaa7f642769abcfbce658aeaaffdc9fb4790cd905
authorEric Blake <ebb9@byu.net>
Thu, 8 Apr 2010 00:16:27 +0000 (7 17:16 -0700)
committerUlrich Drepper <drepper@redhat.com>
Thu, 8 Apr 2010 00:16:27 +0000 (7 17:16 -0700)
treeea9fe568ed20f3a3aefae5ff33f0831fc5d161ea
parent22ef35456ea0b36e09f3241043f894eb71d2c9da
Fix -W with optional parameters in getopt.

According to the getopt documentation, if "W;" is part of optstring, then '-W
foo' should behave like '--foo'.  But if "foo" uses an optional_argument, this
is not the case, since optarg is not NULL when using -W.
ChangeLog
posix/getopt.c