summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libvncclient/rfbproto.c6
-rw-r--r--rfb/rfbproto.h5
2 files changed, 6 insertions, 5 deletions
diff --git a/libvncclient/rfbproto.c b/libvncclient/rfbproto.c
index 602594b..098ae38 100644
--- a/libvncclient/rfbproto.c
+++ b/libvncclient/rfbproto.c
@@ -31,13 +31,9 @@
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
-#else
-#define strncasecmp _strnicmp
-#endif
-#include <errno.h>
-#ifndef WIN32
#include <pwd.h>
#endif
+#include <errno.h>
#include <rfb/rfbclient.h>
#ifdef LIBVNCSERVER_HAVE_LIBZ
#include <zlib.h>
diff --git a/rfb/rfbproto.h b/rfb/rfbproto.h
index 4e80fb3..c20f95c 100644
--- a/rfb/rfbproto.h
+++ b/rfb/rfbproto.h
@@ -74,6 +74,11 @@
#define LIBVNCSERVER_WORDS_BIGENDIAN
#endif
+/* MS compilers don't have strncasecmp */
+#ifdef _MSC_VER
+#define strncasecmp _strnicmp
+#endif
+
#if !defined(WIN32) || defined(__MINGW32__)
#define max(a,b) (((a)>(b))?(a):(b))
#ifdef LIBVNCSERVER_HAVE_SYS_TIME_H
OpenPOWER on IntegriCloud