env: -u option fails due to typo
The -u option is supposed to be allowed to appear multiple times; the option string supplied to getopt32long requires it to be followed by a nonnegative integer. Reported-by: Keith Maxwell <keith.maxwell@gmail.com> Signed-off-by: Ron Yorston <rmy@pobox.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
a07fead823
commit
8d8ee910f0
@ -54,7 +54,7 @@ int env_main(int argc UNUSED_PARAM, char **argv)
|
|||||||
unsigned opts;
|
unsigned opts;
|
||||||
llist_t *unset_env = NULL;
|
llist_t *unset_env = NULL;
|
||||||
|
|
||||||
opts = getopt32long(argv, "+iu:+",
|
opts = getopt32long(argv, "+iu:*",
|
||||||
"ignore-environment\0" No_argument "i"
|
"ignore-environment\0" No_argument "i"
|
||||||
"unset\0" Required_argument "u"
|
"unset\0" Required_argument "u"
|
||||||
, &unset_env
|
, &unset_env
|
||||||
|
Loading…
Reference in New Issue
Block a user