X-Git-Url: http://andersk.mit.edu/gitweb/openssh.git/blobdiff_plain/c1cb7bae1a56520c8bc58c1753faddacb16ac646..a03acb8f71abe2c1128ab91b53922238a2d6042e:/canohost.c diff --git a/canohost.c b/canohost.c index 35ae9bed..2345cc35 100644 --- a/canohost.c +++ b/canohost.c @@ -1,4 +1,4 @@ -/* $OpenBSD: canohost.c,v 1.53 2006/03/25 13:17:01 djm Exp $ */ +/* $OpenBSD: canohost.c,v 1.61 2006/08/03 03:34:41 deraadt Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -14,10 +14,22 @@ #include "includes.h" +#include +#include + +#include +#include + #include +#include +#include +#include +#include +#include +#include -#include "packet.h" #include "xmalloc.h" +#include "packet.h" #include "log.h" #include "canohost.h" @@ -45,6 +57,9 @@ get_remote_hostname(int sock, int use_dns) cleanup_exit(255); } + if (from.ss_family == AF_INET) + check_ip_options(sock, ntop); + ipv64_normalise_mapped(&from, &fromlen); if (from.ss_family == AF_INET6) @@ -54,9 +69,6 @@ get_remote_hostname(int sock, int use_dns) NULL, 0, NI_NUMERICHOST) != 0) fatal("get_remote_hostname: getnameinfo NI_NUMERICHOST failed"); - if (from.ss_family == AF_INET) - check_ip_options(sock, ntop); - if (!use_dns) return xstrdup(ntop);