diff options
author | Martin Sustrik <sustrik@250bpm.com> | 2010-09-01 13:31:45 +0200 |
---|---|---|
committer | Martin Sustrik <sustrik@250bpm.com> | 2010-09-01 13:31:45 +0200 |
commit | 6a0c323bb231a2460c238cd0b93293fcd482f9bc (patch) | |
tree | 06de78687b05853f42940778fb784955d270b7d9 /src | |
parent | ce0972dca3982538fd123b61fbae3928fad6d1e7 (diff) |
MSVC build fixed
Diffstat (limited to 'src')
-rw-r--r-- | src/ctx.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/ctx.cpp b/src/ctx.cpp index f66e1fe..2034f57 100644 --- a/src/ctx.cpp +++ b/src/ctx.cpp @@ -36,12 +36,14 @@ zmq::ctx_t::ctx_t (uint32_t io_threads_) : no_sockets_notify (false) { + int rc; + #ifdef ZMQ_HAVE_WINDOWS // Intialise Windows sockets. Note that WSAStartup can be called multiple // times given that WSACleanup will be called for each WSAStartup. WORD version_requested = MAKEWORD (2, 2); WSADATA wsa_data; - int rc = WSAStartup (version_requested, &wsa_data); + rc = WSAStartup (version_requested, &wsa_data); zmq_assert (rc == 0); zmq_assert (LOBYTE (wsa_data.wVersion) == 2 && HIBYTE (wsa_data.wVersion) == 2); @@ -70,7 +72,7 @@ zmq::ctx_t::ctx_t (uint32_t io_threads_) : // Create the logging infrastructure. log_socket = create_socket (ZMQ_PUB); zmq_assert (log_socket); - int rc = log_socket->bind ("inproc://log"); + rc = log_socket->bind ("inproc://log"); zmq_assert (rc == 0); } |