diff --git a/src/bind.c b/src/bind.c index d0dfa887..babefe4c 100644 --- a/src/bind.c +++ b/src/bind.c @@ -47,8 +47,17 @@ #ifdef _WIN32 - #include +#include + +/* + * is necessary for getaddrinfo before Windows XP, but it isn't + * available on some platforms like MinGW. + */ +#ifdef HAVE_WSPIAPI_H +# include +#endif + #define SOCKOPT_TYPE_ARG4 char /*