]> diplodocus.org Git - nmh/blobdiff - sbr/strcasecmp.c
More replacements of mh_strcasecmp() with strcasecmp().
[nmh] / sbr / strcasecmp.c
index bbb26cbaec9c41c6d45b6ae02673d903149c6e52..c48c9d4ca1fc0824be8e5cb6b59ecaa70e2aacdf 100644 (file)
@@ -2,7 +2,9 @@
 /*
  * strcasecmp.c -- compare strings, ignoring case
  *
 /*
  * strcasecmp.c -- compare strings, ignoring case
  *
- * $Id$
+ * This code is Copyright (c) 2002, by the authors of nmh.  See the
+ * COPYRIGHT file in the root directory of the nmh distribution for
+ * complete copyright information.
  */
 
 #include <h/mh.h>
  */
 
 #include <h/mh.h>
@@ -14,7 +16,7 @@
  */
 
 int
  */
 
 int
-strcasecmp (const char *s1, const char *s2) 
+mh_strcasecmp (const char *s1, const char *s2) 
 {
     const unsigned char *us1, *us2;
 
 {
     const unsigned char *us1, *us2;
 
@@ -22,9 +24,9 @@ strcasecmp (const char *s1, const char *s2)
     us2 = (const unsigned char *) s2;
 
     if (!us1)
     us2 = (const unsigned char *) s2;
 
     if (!us1)
-       us1 = "";
+       us1 = (const unsigned char *) "";
     if (!us2)
     if (!us2)
-       us2 = "";
+       us2 = (const unsigned char *) "";
  
     while (tolower(*us1) == tolower(*us2++)) 
        if (*us1++ == '\0')
  
     while (tolower(*us1) == tolower(*us2++)) 
        if (*us1++ == '\0')
@@ -34,7 +36,7 @@ strcasecmp (const char *s1, const char *s2)
  
 
 int
  
 
 int
-strncasecmp (const char *s1, const char *s2, size_t n)
+mh_strncasecmp (const char *s1, const char *s2, size_t n)
 {
     const unsigned char *us1, *us2;
 
 {
     const unsigned char *us1, *us2;