mirror of
https://frontier.innolan.net/rainlance/c-ares.git
synced 2025-10-06 06:59:25 +00:00
Check for USE_WINSOCK instead of WIN32 where the check was done
to verify winsock API availability.
This commit is contained in:
4
adig.c
4
adig.c
@ -153,8 +153,8 @@ int main(int argc, char **argv)
|
||||
fd_set read_fds, write_fds;
|
||||
struct timeval *tvp, tv;
|
||||
|
||||
#ifdef WIN32
|
||||
WORD wVersionRequested = MAKEWORD(1,1);
|
||||
#ifdef USE_WINSOCK
|
||||
WORD wVersionRequested = MAKEWORD(USE_WINSOCK,USE_WINSOCK);
|
||||
WSADATA wsaData;
|
||||
WSAStartup(wVersionRequested, &wsaData);
|
||||
#endif
|
||||
|
4
ahost.c
4
ahost.c
@ -64,8 +64,8 @@ int main(int argc, char **argv)
|
||||
struct in_addr addr4;
|
||||
struct in6_addr addr6;
|
||||
|
||||
#ifdef WIN32
|
||||
WORD wVersionRequested = MAKEWORD(1,1);
|
||||
#ifdef USE_WINSOCK
|
||||
WORD wVersionRequested = MAKEWORD(USE_WINSOCK,USE_WINSOCK);
|
||||
WSADATA wsaData;
|
||||
WSAStartup(wVersionRequested, &wsaData);
|
||||
#endif
|
||||
|
@ -59,7 +59,7 @@
|
||||
#define TRUE 1
|
||||
#endif
|
||||
|
||||
#if (defined(WIN32) || defined(WATT32)) && !defined(MSDOS)
|
||||
#ifdef USE_WINSOCK
|
||||
#define GET_ERRNO() WSAGetLastError()
|
||||
#else
|
||||
#define GET_ERRNO() errno
|
||||
|
Reference in New Issue
Block a user