ping: Remove an extra new line character

This matches the behavior when an RR truncated route is printed.

Reviewed by:	markj
MFC after:	1 week
Pull Request:	https://github.com/freebsd/freebsd-src/pull/863
Differential Revision:	https://reviews.freebsd.org/D39485
This commit is contained in:
Jose Luis Duran 2023-02-09 15:16:39 -03:00 committed by Mark Johnston
parent 20012a3a1a
commit d2c9a14054
2 changed files with 1 additions and 3 deletions

View file

@ -1406,7 +1406,7 @@ pr_pack(char *buf, ssize_t cc, struct sockaddr_in *from, struct timespec *tv)
(void)putchar('\n');
}
} else
(void)printf("\t(truncated route)\n");
(void)printf("\t(truncated route)");
break;
case IPOPT_RR:
j = cp[IPOPT_OLEN]; /* get length */

View file

@ -859,7 +859,6 @@ def test_ping_46(self, expected):
64 bytes from: icmp_seq=0 ttl= time= ms
LSRR: (truncated route)
--- 192.0.2.2 ping statistics ---
1 packets transmitted, 1 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = /// ms
@ -916,7 +915,6 @@ def test_ping_46(self, expected):
64 bytes from: icmp_seq=0 ttl= time= ms
SSRR: (truncated route)
--- 192.0.2.2 ping statistics ---
1 packets transmitted, 1 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = /// ms