Fossil SCM
Fix build issue for MinGW due to missing 'ws2tcpip.h' functions.
Commit
4c247512a8af92b39a0abfa31ead540b533fcca9
Parent
cfcd9b87dcf54a1…
1 file changed
+3
+3
| --- src/http_socket.c | ||
| +++ src/http_socket.c | ||
| @@ -27,10 +27,13 @@ | ||
| 27 | 27 | */ |
| 28 | 28 | |
| 29 | 29 | #include "config.h" |
| 30 | 30 | #include "http_socket.h" |
| 31 | 31 | #if defined(_WIN32) |
| 32 | +# if !defined(_WIN32_WINNT) | |
| 33 | +# define _WIN32_WINNT 0x0501 | |
| 34 | +# endif | |
| 32 | 35 | # include <winsock2.h> |
| 33 | 36 | # include <ws2tcpip.h> |
| 34 | 37 | #else |
| 35 | 38 | # include <netinet/in.h> |
| 36 | 39 | # include <arpa/inet.h> |
| 37 | 40 |
| --- src/http_socket.c | |
| +++ src/http_socket.c | |
| @@ -27,10 +27,13 @@ | |
| 27 | */ |
| 28 | |
| 29 | #include "config.h" |
| 30 | #include "http_socket.h" |
| 31 | #if defined(_WIN32) |
| 32 | # include <winsock2.h> |
| 33 | # include <ws2tcpip.h> |
| 34 | #else |
| 35 | # include <netinet/in.h> |
| 36 | # include <arpa/inet.h> |
| 37 |
| --- src/http_socket.c | |
| +++ src/http_socket.c | |
| @@ -27,10 +27,13 @@ | |
| 27 | */ |
| 28 | |
| 29 | #include "config.h" |
| 30 | #include "http_socket.h" |
| 31 | #if defined(_WIN32) |
| 32 | # if !defined(_WIN32_WINNT) |
| 33 | # define _WIN32_WINNT 0x0501 |
| 34 | # endif |
| 35 | # include <winsock2.h> |
| 36 | # include <ws2tcpip.h> |
| 37 | #else |
| 38 | # include <netinet/in.h> |
| 39 | # include <arpa/inet.h> |
| 40 |