diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-08-01 15:08:52 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-08-01 15:08:52 +0000 |
commit | e505d47dc80f1eb302167c12618b170fcc0fd90c (patch) | |
tree | 26b2934547da259a67d40f5379cb813f9294370f /src/socket.cpp | |
parent | 821b8f555576af4f55b712bee5632f5cdbd9a16e (diff) |
Fixes for inspsocket in ipv6 environment
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4615 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/socket.cpp')
-rw-r--r-- | src/socket.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/socket.cpp b/src/socket.cpp index 1b8455c65..e4c48dd0c 100644 --- a/src/socket.cpp +++ b/src/socket.cpp @@ -44,7 +44,7 @@ bool BindSocket(int sockfd, insp_sockaddr client, insp_sockaddr server, int port if (*addr == '*') *addr = 0; - if (*addr && !insp_aton(addr,&addy)) + if (*addr && (insp_aton(addr,&addy) < 0)) { /* If they gave a hostname, bind to the IP it resolves to */ if (CleanAndResolve(resolved_addr, addr, true, 1)) @@ -278,5 +278,5 @@ const char* insp_ntoa(insp_inaddr n) int insp_aton(const char* a, insp_inaddr* n) { - return (inet_pton(AF_FAMILY, a, &n) < 0); + return inet_pton(AF_FAMILY, a, &n); } |