diff options
-rw-r--r-- | lib/memcasecmp.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/lib/memcasecmp.c b/lib/memcasecmp.c index 547902895..7e4ab7587 100644 --- a/lib/memcasecmp.c +++ b/lib/memcasecmp.c @@ -5,6 +5,13 @@ #include <sys/types.h> #include <ctype.h> +#if defined (STDC_HEADERS) || (!defined (isascii) && !defined (HAVE_ISASCII)) +#define ISASCII(c) 1 +#else +#define ISASCII(c) isascii(c) +#endif +#define ISUPPER(c) (ISASCII (c) && isupper (c)) + #if _LIBC || STDC_HEADERS # define TOLOWER(c) tolower (c) #else @@ -16,7 +23,10 @@ /* Like memcmp, but ignore differences in case. */ int -memcasecmp (const void *vs1, const void *vs2, size_t n) +memcasecmp (vs1, vs2, n) + const void *vs1; + const void *vs2; + size_t n; { unsigned int i; unsigned char *s1 = (unsigned char *) vs1; |