diff options
Diffstat (limited to 'lib_generic/string.c')
-rw-r--r-- | lib_generic/string.c | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/lib_generic/string.c b/lib_generic/string.c index e0b793abbe..b27d2a1990 100644 --- a/lib_generic/string.c +++ b/lib_generic/string.c @@ -21,38 +21,6 @@ #include <malloc.h> -#if 0 /* not used - was: #ifndef __HAVE_ARCH_STRNICMP */ -/** - * strnicmp - Case insensitive, length-limited string comparison - * @s1: One string - * @s2: The other string - * @len: the maximum number of characters to compare - */ -int strnicmp(const char *s1, const char *s2, size_t len) -{ - /* Yes, Virginia, it had better be unsigned */ - unsigned char c1, c2; - - c1 = 0; c2 = 0; - if (len) { - do { - c1 = *s1; c2 = *s2; - s1++; s2++; - if (!c1) - break; - if (!c2) - break; - if (c1 == c2) - continue; - c1 = tolower(c1); - c2 = tolower(c2); - if (c1 != c2) - break; - } while (--len); - } - return (int)c1 - (int)c2; -} -#endif char * ___strtok; |