[zeromq-dev] [PATCH] Fix incorrect include usage on Windows

Steven McCoy steven.mccoy at miru.hk
Tue Jun 14 00:47:32 CEST 2011


So the question is then, why is Windows NT 3.5 being treated as a supported
platform?  There should be no WinSock version 1 *only *code anywhere in
ZeroMQ.

#include <windows.h>

//  MSVC++ 2005 on Win2000 does not define _WIN32_WINNT.
#ifndef _WIN32_WINNT
#define _WIN32_WINNT WINVER
#endif

//  Enable winsock (not included when WIN32_LEAN_AND_MEAN is defined).
#if(_WIN32_WINNT >= 0x0400)
#include <winsock2.h>
#include <mswsock.h>
#else
#include <winsock.h>
#endif

-- 
Steve-o
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20110613/d65df419/attachment.htm>


More information about the zeromq-dev mailing list