summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorPierre Ossman <ossman@cendio.se>2015-03-17 17:10:10 +0100
committerPierre Ossman <ossman@cendio.se>2015-03-17 17:18:50 +0100
commit9d78440b8354ae81f3fc094569f710c27f3ad0e6 (patch)
tree0272281130b355b86ad8cd670d3e390f5313b3ca /common
parenta6570c5da35b036df93da9f19182b4a4d9e8e6cc (diff)
downloadtigervnc-9d78440b8354ae81f3fc094569f710c27f3ad0e6.tar.gz
tigervnc-9d78440b8354ae81f3fc094569f710c27f3ad0e6.zip
Make sure Win32 sockets are available in new listening API
Diffstat (limited to 'common')
-rw-r--r--common/network/TcpSocket.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/common/network/TcpSocket.cxx b/common/network/TcpSocket.cxx
index 5ce7bc31..26ea1f5e 100644
--- a/common/network/TcpSocket.cxx
+++ b/common/network/TcpSocket.cxx
@@ -543,6 +543,9 @@ void network::createLocalTcpListeners(std::list<TcpListener> *listeners,
{
std::list<TcpListener> new_listeners;
vnc_sockaddr_t sa;
+
+ initSockets();
+
#ifdef HAVE_GETADDRINFO
if (UseIPv6) {
sa.u.sin6.sin6_family = AF_INET6;
@@ -591,6 +594,8 @@ void network::createTcpListeners(std::list<TcpListener> *listeners,
struct addrinfo *ai, *current, hints;
char service[16];
+ initSockets();
+
memset(&hints, 0, sizeof(struct addrinfo));
hints.ai_flags = AI_PASSIVE | AI_NUMERICSERV;
hints.ai_family = AF_UNSPEC;