diff options
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/libc/stdlib/getopt_long.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/lib/libc/stdlib/getopt_long.c b/src/lib/libc/stdlib/getopt_long.c index f46cd8bf4e..21407824dd 100644 --- a/src/lib/libc/stdlib/getopt_long.c +++ b/src/lib/libc/stdlib/getopt_long.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: getopt_long.c,v 1.26 2013/06/08 22:47:56 millert Exp $ */ | 1 | /* $OpenBSD: getopt_long.c,v 1.27 2015/09/12 14:48:14 guenther Exp $ */ |
2 | /* $NetBSD: getopt_long.c,v 1.15 2002/01/31 22:43:40 tv Exp $ */ | 2 | /* $NetBSD: getopt_long.c,v 1.15 2002/01/31 22:43:40 tv Exp $ */ |
3 | 3 | ||
4 | /* | 4 | /* |
@@ -61,6 +61,11 @@ int optopt = '?'; /* character checked for validity */ | |||
61 | int optreset; /* reset getopt */ | 61 | int optreset; /* reset getopt */ |
62 | char *optarg; /* argument associated with option */ | 62 | char *optarg; /* argument associated with option */ |
63 | 63 | ||
64 | /* DEF_* only work on initialized (non-COMMON) variables */ | ||
65 | DEF_WEAK(opterr); | ||
66 | DEF_WEAK(optind); | ||
67 | DEF_WEAK(optopt); | ||
68 | |||
64 | #define PRINT_ERROR ((opterr) && (*options != ':')) | 69 | #define PRINT_ERROR ((opterr) && (*options != ':')) |
65 | 70 | ||
66 | #define FLAG_PERMUTE 0x01 /* permute non-options to the end of argv */ | 71 | #define FLAG_PERMUTE 0x01 /* permute non-options to the end of argv */ |