summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorflorian <florian@openbsd.org>2016-09-03 21:50:52 +0000
committerflorian <florian@openbsd.org>2016-09-03 21:50:52 +0000
commit830c54f95380a07ba8973d8e926543404686f2c6 (patch)
treef2517c2caadbe7e961c65b710733cd793517191f
parents/to/dst/ (diff)
downloadwireguard-openbsd-830c54f95380a07ba8973d8e926543404686f2c6.tar.xz
wireguard-openbsd-830c54f95380a07ba8973d8e926543404686f2c6.zip
How can this not be AF_INET?!
-rw-r--r--sbin/ping/ping.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/sbin/ping/ping.c b/sbin/ping/ping.c
index 1f56d8cdb04..4aea1d261ed 100644
--- a/sbin/ping/ping.c
+++ b/sbin/ping/ping.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ping.c,v 1.146 2016/09/03 21:49:55 florian Exp $ */
+/* $OpenBSD: ping.c,v 1.147 2016/09/03 21:50:52 florian Exp $ */
/* $NetBSD: ping.c,v 1.20 1995/08/11 22:37:58 cgd Exp $ */
/*
@@ -498,12 +498,8 @@ main(int argc, char *argv[])
warnx("Could only allocate a receive buffer of %d bytes (default %d)",
bufspace, IP_MAXPACKET);
- if (dst.sin_family == AF_INET)
- (void)printf("PING %s (%s): %d data bytes\n", hostname,
- pr_addr((struct sockaddr *)&dst, sizeof(dst)),
- datalen);
- else
- (void)printf("PING %s: %d data bytes\n", hostname, datalen);
+ (void)printf("PING %s (%s): %d data bytes\n", hostname,
+ pr_addr((struct sockaddr *)&dst, sizeof(dst)), datalen);
if (options & F_HOSTNAME) {
if (pledge("stdio inet dns", NULL) == -1)