net_sys.h: the new MS SDKs define EWOULDBLOCK and ECONNREFUSED,

so we must undefine them before redefining.

git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@397 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
Ozkan Sezer 2011-01-12 12:39:24 +00:00
parent 1f10c40b9f
commit 744c346b3f

View file

@ -142,7 +142,11 @@ typedef int socklen_t;
typedef SOCKET sys_socket_t; typedef SOCKET sys_socket_t;
#define SOCKETERRNO WSAGetLastError() #define SOCKETERRNO WSAGetLastError()
/* the new MS SDKs define the following two,
* so we must undefine them before redefining. */
#undef EWOULDBLOCK
#define EWOULDBLOCK WSAEWOULDBLOCK #define EWOULDBLOCK WSAEWOULDBLOCK
#undef ECONNREFUSED
#define ECONNREFUSED WSAECONNREFUSED #define ECONNREFUSED WSAECONNREFUSED
/* must #include "wsaerror.h" for this : */ /* must #include "wsaerror.h" for this : */
#define socketerror(x) __WSAE_StrError((x)) #define socketerror(x) __WSAE_StrError((x))