diff options
author | Damien Miller <djm@mindrot.org> | 1999-12-18 20:57:40 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 1999-12-18 20:57:40 +1100 |
commit | fdb7caf293e860fda343f9cc98ff3342ed997b73 (patch) | |
tree | 81cdfa33653f0ff28f85b0a0b8a00235990206de /canohost.c | |
parent | c4c647fb9465ae98816c5a6a1a6d9dae0e383e9a (diff) |
Avoid breakage on systems lacking IPv6 headers
Diffstat (limited to 'canohost.c')
-rw-r--r-- | canohost.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -14,7 +14,7 @@ */ #include "includes.h" -RCSID("$Id: canohost.c,v 1.5 1999/12/13 23:47:15 damien Exp $"); +RCSID("$Id: canohost.c,v 1.6 1999/12/18 09:57:40 damien Exp $"); #include "packet.h" #include "xmalloc.h" @@ -160,8 +160,9 @@ peer_connection_is_on_socket() memset(&from, 0, sizeof(from)); if (getpeername(in, (struct sockaddr *) & from, &fromlen) < 0) return 0; - if (from.sin_family != AF_INET && from.sin_family != AF_INET6) + if (from.sin_family != AF_INET) return 0; + return 1; } |