Commit 072347166f78408dd4a92cb3b75f6673b71a0f7e

Sebastian Schuberth 2011-05-18T16:46:56

Define str(n)casecmp for MSVC MSVC has _str(n)icmp instead.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
diff --git a/src/msvc-compat.h b/src/msvc-compat.h
index d4c031d..7422a7a 100644
--- a/src/msvc-compat.h
+++ b/src/msvc-compat.h
@@ -17,6 +17,10 @@
 # define S_ISREG(m)   (((m) & _S_IFMT) == _S_IFREG)
 # define S_ISFIFO(m)  (((m) & _S_IFMT) == _S_IFIFO)
 
+/* case-insensitive string comparision */
+# define strcasecmp   _stricmp
+# define strncasecmp  _strnicmp
+
 #if (_MSC_VER >= 1600)
 #	include <stdint.h>
 #else