- NSS 3.14.x
- Heimdal ?
- nghttp2 1.12.0
+ - WinSock 2.2 (on Windows 95+ and Windows CE .NET 4.1+)
Operating Systems
-----------------
also do it etc there might be reasons for applications to alter that
behaviour.
+ We require WinSock version 2.2 and load this version during global init.
+
3. The file descriptors for network communication and file operations are
not as easily interchangeable as in Unix.
/* ---------------------------------------------------------------- */
-/*
- * When using WINSOCK, TELNET protocol requires WINSOCK2 API.
- */
-
-#if defined(USE_WINSOCK) && (USE_WINSOCK != 2)
-# define CURL_DISABLE_TELNET 1
-#endif
-
/*
* msvc 6.0 does not have struct sockaddr_storage and
* does not define IPPROTO_ESP in winsock2.h. But both
defined(HAVE_WINSOCK_H) || \
defined(HAVE_WINSOCK2_H) || \
defined(HAVE_WS2TCPIP_H)
-# error "Winsock and lwIP TCP/IP stack definitions shall not coexist!"
+# error "WinSock and lwIP TCP/IP stack definitions shall not coexist!"
# endif
#endif
/*
* Define USE_WINSOCK to 2 if we have and use WINSOCK2 API, else
- * define USE_WINSOCK to 1 if we have and use WINSOCK API, else
* undefine USE_WINSOCK.
*/
# define USE_WINSOCK 2
#else
# ifdef HAVE_WINSOCK_H
-# define USE_WINSOCK 1
+# error "WinSock version 1 is no longer supported, version 2 is required!"
# endif
#endif
WSADATA wsaData;
int res;
-#if defined(ENABLE_IPV6) && (USE_WINSOCK < 2)
-#error IPV6_requires_winsock2
-#endif
-
- wVersionRequested = MAKEWORD(USE_WINSOCK, USE_WINSOCK);
-
+ wVersionRequested = MAKEWORD(2, 2);
res = WSAStartup(wVersionRequested, &wsaData);
if(res != 0)
return CURLE_FAILED_INIT;
}
/* The Windows Sockets DLL is acceptable. Proceed. */
- #elif defined(USE_LWIPSOCK)
+#elif defined(USE_LWIPSOCK)
lwip_init();
- #endif
+#endif
} /* CURL_GLOBAL_WIN32 */
#ifdef USE_WINDOWS_SSPI
WORD wVersionRequested;
WSADATA wsaData;
int err;
- wVersionRequested = MAKEWORD(USE_WINSOCK, USE_WINSOCK);
+ wVersionRequested = MAKEWORD(2, 2);
err = WSAStartup(wVersionRequested, &wsaData);
if(err != 0) {
exit(1);
}
- if(LOBYTE(wsaData.wVersion) != USE_WINSOCK ||
- HIBYTE(wsaData.wVersion) != USE_WINSOCK) {
+ if(LOBYTE(wsaData.wVersion) != LOBYTE(wVersionRequested) ||
+ HIBYTE(wsaData.wVersion) != HIBYTE(wVersionRequested) ) {
WSACleanup();
perror("Winsock init failed");
logmsg("No suitable winsock.dll found -- aborting");