From ce580280f402f881c6277a6eec42effcdd1d40db Mon Sep 17 00:00:00 2001 From: ache Date: Mon, 1 Mar 2004 10:03:34 +0000 Subject: Change "-"-started options when POSIX_CORRECTLY is set handling in favour of GNU instead of NetBSD, because configure's use us and expect GNU. --- lib/libc/stdlib/getopt_long.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'lib/libc/stdlib/getopt_long.c') diff --git a/lib/libc/stdlib/getopt_long.c b/lib/libc/stdlib/getopt_long.c index 54427ef..92cffab 100644 --- a/lib/libc/stdlib/getopt_long.c +++ b/lib/libc/stdlib/getopt_long.c @@ -313,7 +313,11 @@ getopt_internal(int nargc, char * const *nargv, const char *options, posixly_correct = (getenv("POSIXLY_CORRECT") != NULL); if (posixly_correct || *options == '+') flags &= ~FLAG_PERMUTE; - else if (*options == '-') + /* + * Code "else if (*options == '-')" was here. + * Try to be more GNU compatible, configure's use us! + */ + if (*options == '-') flags |= FLAG_ALLARGS; if (*options == '+' || *options == '-') options++; -- cgit v1.1