summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
authorDamien Miller <djm@cvs.openbsd.org>2004-03-31 21:58:48 +0000
committerDamien Miller <djm@cvs.openbsd.org>2004-03-31 21:58:48 +0000
commit2d0e52ad298163143ca271ad802c8319f7e50f77 (patch)
treeed207f6bbb9ae203c35825801d48d2a25d2272a4 /usr.bin
parent778c2f82d95aa26bd930ada16d267cbe2939391a (diff)
don't skip ip options check when UseDNS=no; ok markus@
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/ssh/canohost.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.bin/ssh/canohost.c b/usr.bin/ssh/canohost.c
index 49089747fd9..b578ae66137 100644
--- a/usr.bin/ssh/canohost.c
+++ b/usr.bin/ssh/canohost.c
@@ -12,7 +12,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: canohost.c,v 1.38 2003/09/23 20:17:11 markus Exp $");
+RCSID("$OpenBSD: canohost.c,v 1.39 2004/03/31 21:58:47 djm Exp $");
#include "packet.h"
#include "xmalloc.h"
@@ -43,6 +43,9 @@ get_remote_hostname(int socket, int use_dns)
cleanup_exit(255);
}
+ if (from.ss_family == AF_INET)
+ check_ip_options(socket, ntop);
+
if (getnameinfo((struct sockaddr *)&from, fromlen, ntop, sizeof(ntop),
NULL, 0, NI_NUMERICHOST) != 0)
fatal("get_remote_hostname: getnameinfo NI_NUMERICHOST failed");
@@ -50,9 +53,6 @@ get_remote_hostname(int socket, int use_dns)
if (!use_dns)
return xstrdup(ntop);
- if (from.ss_family == AF_INET)
- check_ip_options(socket, ntop);
-
debug3("Trying to reverse map address %.100s.", ntop);
/* Map the IP address to a host name. */
if (getnameinfo((struct sockaddr *)&from, fromlen, name, sizeof(name),