From fe1b58200a3bc116b72927fad2ebd0d051f88e17 Mon Sep 17 00:00:00 2001 From: Stephen Hurd <deuce@synchro.net> Date: Tue, 8 Feb 2022 22:20:35 -0500 Subject: [PATCH] Don't try to include wspiapi.h on XP or newer --- xpdev/sockwrap.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/xpdev/sockwrap.h b/xpdev/sockwrap.h index 7dd07a1..b5d3866 100644 --- a/xpdev/sockwrap.h +++ b/xpdev/sockwrap.h @@ -40,7 +40,9 @@ #if defined(__BORLANDC__) #undef _MSC_VER #endif - #include <wspiapi.h> /* getaddrinfo() for Windows 2k */ + #if (_WIN32_WINNT < _WIN32_WINNT_WINXP) + #include <wspiapi.h> /* getaddrinfo() for Windows 2k */ + #endif #define SOCK_MAXADDRLEN sizeof(SOCKADDR_STORAGE) /* Let's agree on a standard WinSock symbol here, people */ #define _WINSOCKAPI_ -- GitLab