Close socket:return false 340/head
authorsvost <ya.nowa@yandex.ru>
Tue, 3 May 2016 18:49:38 +0000 (21:49 +0300)
committersvost <ya.nowa@yandex.ru>
Tue, 3 May 2016 18:49:38 +0000 (21:49 +0300)
src/net.cpp

index a1d9e33..f711696 100644 (file)
@@ -1791,6 +1791,7 @@ bool BindListenPort(const CService &addrBind, string& strError)
     {
         strError = strprintf("Error: Couldn't set properties on socket for incoming connections (error %d)", WSAGetLastError());
         printf("%s\n", strError.c_str());
+        CloseSocket(hSocket);
         return false;
     }