diff options
Diffstat (limited to 'posix')
-rw-r--r-- | posix/getopt.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/posix/getopt.c b/posix/getopt.c index 4cbf3614cc..4d837c041a 100644 --- a/posix/getopt.c +++ b/posix/getopt.c @@ -198,15 +198,18 @@ static char *posixly_correct; # define my_index strchr #else +# if HAVE_STRING_H +# include <string.h> +# else +# include <strings.h> +# endif + /* Avoid depending on library functions or files whose names are inconsistent. */ #ifndef getenv extern char *getenv (); #endif -#ifndef strncmp -extern int strncmp (); -#endif static char * my_index (str, chr) |