commit | da9a38d4e9ded0901db1bd4b6144f0213ebecea7 | [log] [tgz] |
---|---|---|
author | Pierre Ossman <ossman@cendio.se> | Tue Mar 03 16:03:32 2015 +0100 |
committer | Pierre Ossman <ossman@cendio.se> | Tue Mar 03 16:03:32 2015 +0100 |
tree | 8c8c1d564423b884a4f1bc1df0e8ea2d62f30d64 | |
parent | f1a3501750afeba2b750dc2cf64b017f795e2e4e [diff] [blame] |
Handle no useful address types from getaddrinfo()
diff --git a/common/network/TcpSocket.cxx b/common/network/TcpSocket.cxx index 5158e80..ef7f55d 100644 --- a/common/network/TcpSocket.cxx +++ b/common/network/TcpSocket.cxx
@@ -234,6 +234,9 @@ } freeaddrinfo(ai); + + if (current == NULL) + throw Exception("No useful address for host"); #endif /* HAVE_GETADDRINFO */ if (result == -1)