diff options
author | Jack Lloyd <[email protected]> | 2017-09-10 06:47:57 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2017-09-10 07:29:57 -0400 |
commit | f353dc369ddf6d460f7979ad87e974afa52e8536 (patch) | |
tree | 9275dbae8761462a8bb940028d4a7385e1af1ad5 /src/lib | |
parent | a0273956a678b90bbd70da083b6cdafb2d9d6558 (diff) |
Fix bad comparison in Winsock code
[ci skip]
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/utils/os_utils.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/utils/os_utils.cpp b/src/lib/utils/os_utils.cpp index 297316152..261fb5f1f 100644 --- a/src/lib/utils/os_utils.cpp +++ b/src/lib/utils/os_utils.cpp @@ -122,7 +122,7 @@ OS::open_socket(const std::string& hostname, throw Exception("Name resolution failed for " + hostname); } - for(addrinfo* rp = res; (m_socket < 0) && (rp != nullptr); rp = rp->ai_next) + for(addrinfo* rp = res; (m_socket == INVALID_SOCKET) && (rp != nullptr); rp = rp->ai_next) { m_socket = ::socket(rp->ai_family, rp->ai_socktype, rp->ai_protocol); |