mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-03-30 07:20:59 +00:00
Don't force the _WIN32_WINT version
If the user has set a value in the build environment, it will be used. Otherwise, if SDK has a default value, it will be picked. If either of these values are lower than 0x0501 (XP) we should not force some calls that will not work on the minimum target OS. We should use dynamic loading of these API's to support them in higher versions of the OS. winsock2.h needs to be included before windows.h and will pick the default _WIN32_WINNT from the SDK or use the one from the user, by setting _WIN32_WINNT in the CFLAGS. Signed-off-by: Steve Lhomme <robux4@ycbcr.xyz>
This commit is contained in:
parent
4000b6ec0e
commit
551b3bf4bb
@ -49,11 +49,6 @@
|
||||
|
||||
#define IS_EINTR(ret) ((ret) == WSAEINTR)
|
||||
|
||||
#if !defined(_WIN32_WINNT)
|
||||
/* Enables getaddrinfo() & Co */
|
||||
#define _WIN32_WINNT 0x0501
|
||||
#endif
|
||||
|
||||
#include <ws2tcpip.h>
|
||||
|
||||
#include <winsock2.h>
|
||||
|
Loading…
x
Reference in New Issue
Block a user