diff options
author | Pierre Ossman <ossman@cendio.se> | 2015-03-03 16:03:32 +0100 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2015-03-03 16:03:32 +0100 |
commit | da9a38d4e9ded0901db1bd4b6144f0213ebecea7 (patch) | |
tree | 8c8c1d564423b884a4f1bc1df0e8ea2d62f30d64 /common/network | |
parent | f1a3501750afeba2b750dc2cf64b017f795e2e4e (diff) | |
download | tigervnc-da9a38d4e9ded0901db1bd4b6144f0213ebecea7.tar.gz tigervnc-da9a38d4e9ded0901db1bd4b6144f0213ebecea7.zip |
Handle no useful address types from getaddrinfo()
Diffstat (limited to 'common/network')
-rw-r--r-- | common/network/TcpSocket.cxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/common/network/TcpSocket.cxx b/common/network/TcpSocket.cxx index 5158e805..ef7f55db 100644 --- a/common/network/TcpSocket.cxx +++ b/common/network/TcpSocket.cxx @@ -234,6 +234,9 @@ TcpSocket::TcpSocket(const char *host, int port) } freeaddrinfo(ai); + + if (current == NULL) + throw Exception("No useful address for host"); #endif /* HAVE_GETADDRINFO */ if (result == -1) |