summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-08-14 02:50:05 +0000
committerJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2000-08-14 02:50:05 +0000
commit03c953e2b7b9cd9b091d500edb22912b0ea187f3 (patch)
tree1d7f9bee867dc62c292cbf0f609696a5d163f8e0
parent70c409c6ac15a2edd005d6d3e822b32152610fa5 (diff)
correct truncated FQDN printing
-rw-r--r--sbin/ping6/ping6.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sbin/ping6/ping6.c b/sbin/ping6/ping6.c
index 19c86ce154a..3a2ed343dac 100644
--- a/sbin/ping6/ping6.c
+++ b/sbin/ping6/ping6.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: ping6.c,v 1.10 2000/08/13 20:17:00 itojun Exp $ */
-/* $KAME: ping6.c,v 1.72 2000/08/13 20:12:48 itojun Exp $ */
+/* $OpenBSD: ping6.c,v 1.11 2000/08/14 02:50:04 itojun Exp $ */
+/* $KAME: ping6.c,v 1.74 2000/08/14 02:48:14 itojun Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -1397,7 +1397,7 @@ pr_pack(buf, cc, mhdr)
* name-lookup special handling for
* truncated name
*/
- if (cp + 1 < end && !*cp &&
+ if (cp + 1 <= end && !*cp &&
strlen(dnsname) > 0) {
dnsname[strlen(dnsname) - 1] = '\0';
cp++;
@@ -1740,7 +1740,6 @@ onint(notused)
void
summary()
{
- register int i;
(void)printf("\n--- %s ping6 statistics ---\n", hostname);
(void)printf("%ld packets transmitted, ", ntransmitted);