summaryrefslogtreecommitdiffstats
path: root/rfb
diff options
context:
space:
mode:
Diffstat (limited to 'rfb')
-rw-r--r--rfb/rfb.h4
-rw-r--r--rfb/rfbclient.h4
2 files changed, 6 insertions, 2 deletions
diff --git a/rfb/rfb.h b/rfb/rfb.h
index 16b6b66..f7919c6 100644
--- a/rfb/rfb.h
+++ b/rfb/rfb.h
@@ -52,7 +52,7 @@ extern "C"
#include <sys/types.h>
#endif
-#ifdef __MINGW32__
+#ifdef WIN32
#undef SOCKET
#include <winsock2.h>
#ifdef LIBVNCSERVER_HAVE_WS2TCPIP_H
@@ -267,7 +267,7 @@ typedef struct _rfbScreenInfo
SOCKET listenSock;
int maxSock;
int maxFd;
-#ifdef __MINGW32__
+#ifdef WIN32
struct fd_set allFds;
#else
fd_set allFds;
diff --git a/rfb/rfbclient.h b/rfb/rfbclient.h
index 9ac3c37..aedb4f4 100644
--- a/rfb/rfbclient.h
+++ b/rfb/rfbclient.h
@@ -31,6 +31,10 @@
* @file rfbclient.h
*/
+#ifdef WIN32
+#define WIN32_LEAN_AND_MEAN /* Prevent loading any Winsock 1.x headers from windows.h */
+#endif
+
#include <stdio.h>
#include <stdlib.h>
#include <string.h>