diff options
author | Simon Josefsson <simon@josefsson.org> | 2006-01-27 12:51:49 +0000 |
---|---|---|
committer | Simon Josefsson <simon@josefsson.org> | 2006-01-27 12:51:49 +0000 |
commit | 08ba0ed64f5d371162df656e0e163decfb53535a (patch) | |
tree | fab00063476923d4fdf265730262f76f7290b0c7 /gl/socket_.h | |
parent | 986d43b25429edf54a28fd9c30954dd2fbf8eda7 (diff) | |
download | gnutls-08ba0ed64f5d371162df656e0e163decfb53535a.tar.gz |
Update.
Diffstat (limited to 'gl/socket_.h')
-rw-r--r-- | gl/socket_.h | 28 |
1 files changed, 22 insertions, 6 deletions
diff --git a/gl/socket_.h b/gl/socket_.h index 8d3c0777a6..ce1edbb417 100644 --- a/gl/socket_.h +++ b/gl/socket_.h @@ -28,6 +28,22 @@ we need. */ #if HAVE_WINSOCK2_H +/* The following define makes sure we get all the prototypes from the + header files. getaddrinfo is only available if _WIN32_WINNT >= + 0x0501 (that symbol is set indiriectly through WINVER). This has + the following two (potential) problems: + + 1) winsock2.h must not have been included before this symbol + is set (I think). + + 2) There may be some _reason_ for all prototypes not being + available with the default settings. Such as if some APIs are + not available on older Windows hosts. However, getaddrinfo + (which need >= 0x0501) should be available on Windows 95 and + later, according to: + http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/winsock/getaddrinfo_2.asp +*/ +#define WINVER 0x0501 # include <winsock2.h> #endif #if HAVE_WS2TCPIP_H @@ -35,14 +51,14 @@ #endif /* For shutdown(). */ -#ifndef SHUT_RD -# define SHUT_RD 0 +#if !defined SHUT_RD && defined SD_RECEIVE +# define SHUT_RD SD_RECEIVE #endif -#ifndef SHUT_WR -# define SHUT_WR 1 +#if !defined SHUT_WR && defined SD_SEND +# define SHUT_WR SD_SEND #endif -#ifndef SHUT_RDWR -# define SHUT_RDWR 2 +#if !defined SHUT_RDWR && defined SD_BOTH +# define SHUT_RDWR SD_BOTH #endif #endif /* _SYS_SOCKET_H */ |