summaryrefslogtreecommitdiff
path: root/src/ctx.cpp
diff options
context:
space:
mode:
authorSteven McCoy <steven.mccoy@miru.hk>2011-06-12 19:37:11 +0200
committerMartin Sustrik <sustrik@250bpm.com>2011-06-12 19:37:11 +0200
commitb164023cca3f29c5eb371a8a0757c98ae4683ae4 (patch)
tree48637be1f5611a4f98601a159ea26a8857d37014 /src/ctx.cpp
parentff93f54653d099bddfed34a342906a3546e70496 (diff)
Fix scope on Windows includes.
Fix windows.h included before winsock2.h. Remove definition of _WINSOCKAPI_. Signed-off-by: Steven McCoy <steven.mccoy@miru.hk>
Diffstat (limited to 'src/ctx.cpp')
-rw-r--r--src/ctx.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/ctx.cpp b/src/ctx.cpp
index fb5420d..6d6242e 100644
--- a/src/ctx.cpp
+++ b/src/ctx.cpp
@@ -31,9 +31,13 @@
#include "msg.hpp"
#if defined ZMQ_HAVE_WINDOWS
-#include "windows.h"
+#ifndef WIN32_LEAN_AND_MEAN
+#define WIN32_LEAN_AND_MEAN
+#endif
+#include <winsock2.h>
+#include <windows.h>
#else
-#include "unistd.h"
+#include <unistd.h>
#endif
zmq::ctx_t::ctx_t (uint32_t io_threads_) :