mirror of
https://github.com/libevent/libevent.git
synced 2025-01-09 00:56:20 +08:00
Fix winsock2.h #include issues with MSVC
Define WIN32_LEAN_AND_MEAN, so that windows.h does not bring in winsock.h which in turn makes it impossible to #include <winsock2.h> (at least with MSVC)
This commit is contained in:
parent
8fa030c032
commit
3d768dc967
@ -41,6 +41,7 @@
|
||||
#include <sys/time.h>
|
||||
#endif
|
||||
#ifdef WIN32
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <windows.h>
|
||||
#else
|
||||
#include <sys/socket.h>
|
||||
|
@ -33,6 +33,7 @@
|
||||
#include <sys/time.h>
|
||||
#endif
|
||||
#ifdef WIN32
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <windows.h>
|
||||
#else
|
||||
#include <sys/socket.h>
|
||||
|
Loading…
x
Reference in New Issue
Block a user