fixed multiple definition of stricmp
[NeonServV5.git] / main.h
diff --git a/main.h b/main.h
index f88388b7b8e0176ede230623ad387ddbf2b9246a..c25d743239b8fece8b37a3c1b9fac8914aa243bb 100644 (file)
--- a/main.h
+++ b/main.h
 #define UNUSED_ARG(ARG) ARG
 #endif
 
-int stricmp (const char *s1, const char *s2)
-{
-   if (s1 == NULL) return s2 == NULL ? 0 : -(*s2);
-   if (s2 == NULL) return *s1;
-   char c1, c2;
-   while ((c1 = tolower (*s1)) == (c2 = tolower (*s2)))
-   {
-     if (*s1 == '\0') break;
-     ++s1; ++s2;
-   }
-   return c1 - c2;
-}
-
 #define SOCKET_SELECT_TIME 2
 
 #define NICKLEN         30
@@ -63,4 +50,6 @@ int stricmp (const char *s1, const char *s2)
 
 #define TEMPUSER_LIST_INDEX VALID_NICK_CHARS_FIRST_LEN
 
+int stricmp (const char *s1, const char *s2);
+
 #endif
\ No newline at end of file