diff --git a/ares/ares.h b/ares/ares.h index 695f8aafb..7f76112f7 100644 --- a/ares/ares.h +++ b/ares/ares.h @@ -31,7 +31,10 @@ #include #include #include -#elif !defined(WIN32) +#elif defined(WIN32) + #include + #include +#else #include #include #endif diff --git a/ares/nameser.h b/ares/nameser.h index 0ccbfd1c0..7127c2640 100644 --- a/ares/nameser.h +++ b/ares/nameser.h @@ -7,6 +7,7 @@ port build */ #ifndef NETWARE +#include #include /* for the _getpid() proto */ #endif /* !NETWARE */ #include diff --git a/include/curl/multi.h b/include/curl/multi.h index 35cf34885..96c2763ef 100644 --- a/include/curl/multi.h +++ b/include/curl/multi.h @@ -45,7 +45,11 @@ #if defined(WIN32) && !defined(_WIN32_WCE) && !defined(__GNUC__) || \ defined(__MINGW32__) - +#if !(defined(_WINSOCKAPI_) || defined(_WINSOCK_H)) +/* The check above prevents the winsock2 inclusion if winsock.h already was + included, since they can't co-exist without problems */ +#include +#endif #else /* HP-UX systems version 9, 10 and 11 lack sys/select.h and so does oldish