From d23fa49c52e9e0310f938379c5af91f0b4e5fe46 Mon Sep 17 00:00:00 2001 From: "Wladimir J. van der Laan" Date: Sun, 28 Apr 2013 08:51:49 +0200 Subject: move WSAStartup to init WSAStartup should be called before using any other socket functions. BindListenPort is not called if not listening. Closes #2585. --- src/net.cpp | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'src/net.cpp') diff --git a/src/net.cpp b/src/net.cpp index 755312682..031126180 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -1653,18 +1653,6 @@ bool BindListenPort(const CService &addrBind, string& strError) strError = ""; int nOne = 1; -#ifdef WIN32 - // Initialize Windows Sockets - WSADATA wsadata; - int ret = WSAStartup(MAKEWORD(2,2), &wsadata); - if (ret != NO_ERROR) - { - strError = strprintf("Error: TCP/IP socket library failed to start (WSAStartup returned error %d)", ret); - printf("%s\n", strError.c_str()); - return false; - } -#endif - // Create socket for listening for incoming connections #ifdef USE_IPV6 struct sockaddr_storage sockaddr; -- cgit v1.2.3