From ad55d5131b57f3aee1b3baad61a44c1a48a996a3 Mon Sep 17 00:00:00 2001 From: Jun-ichiro itojun Hagino Date: Sat, 27 Jan 2001 03:23:32 +0000 Subject: correct 1.28 -> 1.29 (ortentry removal, cmetz). can't use routename() here since it could overwrite DNS lookup result pointed to by "hp". maybe we need to change every gethostby* to get*info. --- sbin/route/route.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'sbin') diff --git a/sbin/route/route.c b/sbin/route/route.c index 5c9731ed1f4..36d80cca241 100644 --- a/sbin/route/route.c +++ b/sbin/route/route.c @@ -1,4 +1,4 @@ -/* $OpenBSD: route.c,v 1.40 2000/09/24 01:02:24 millert Exp $ */ +/* $OpenBSD: route.c,v 1.41 2001/01/27 03:23:31 itojun Exp $ */ /* $NetBSD: route.c,v 1.16 1996/04/15 18:27:05 cgd Exp $ */ /* @@ -44,7 +44,7 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)route.c 8.3 (Berkeley) 3/19/94"; #else -static char rcsid[] = "$OpenBSD: route.c,v 1.40 2000/09/24 01:02:24 millert Exp $"; +static char rcsid[] = "$OpenBSD: route.c,v 1.41 2001/01/27 03:23:31 itojun Exp $"; #endif #endif /* not lint */ @@ -823,7 +823,8 @@ newroute(argc, argv) if (*gateway) { (void) printf(": gateway %s", gateway); if (attempts > 1 && ret == 0 && af == AF_INET) - (void) printf(" (%s)", routename(&so_gate.sa)); + (void) printf(" (%s)", + inet_ntoa(so_gate.sin.sin_addr)); } if (ret == 0) (void) printf("\n"); -- cgit v1.2.3