freebsd-src/sbin/ping/tests
Alan Somers 9ce201f2ee ping: fix parsing of options including '4' and '6'
ping uses a two-pass option parser.  The first pass determines whether
ipv4 or ipv6 is desired, and the second parses the rest of the options.
But the first pass wrongly detects a '4' or '6' in an option's value as
a request to use ipv6 or ipv6 respectively, for example in an invocation
like "ping -c6 1.2.3.4".

Fix this confusion by including all options in the first round of
parsing, but ignoring those unrelated to ipv4/ipv6 selection.

PR:		258048
Reported by:	ghuckriede@blackberry.com
Submitted by:	ghuckriede@blackberry.com
MFC after:	2 weeks
Reviewed by:	emaste
Differential Revision: https://reviews.freebsd.org/D32344
2021-10-20 18:05:43 -06:00
..
in_cksum_test.c ICMP checksum test: Fix for big endian 2021-01-11 19:03:46 -07:00
Makefile Merge ping6 to ping 2020-11-26 04:29:30 +00:00
ping_6_c1_s8_t1.out Merge ping6 to ping 2020-11-26 04:29:30 +00:00
ping_c1_s56_t1.out ping: By default, don't reverse lookup IP addresses 2019-08-22 18:57:24 +00:00
ping_test.sh ping: fix parsing of options including '4' and '6' 2021-10-20 18:05:43 -06:00