Eugene Grosbein c0a3773ad2 ping(8): improve diagnostics in case of wrong arguments.
For example, in case of super-user:
$ sudo ping -s -64 127.0.0.1
PING 127.0.0.1 (127.0.0.1): -64 data bytes
ping: sendto: Invalid argument

For unprivileged user:
$ ping -s -64 127.0.0.1
ping: packet size too large: 18446744073709551552 > 56: Operation not permitted

Fix this by switching from strtoul() to strtol() for integer arguments
and adding explicit checks for negative values.

MFC after:	1 month
2018-11-08 09:45:13 +00:00
..
2018-09-18 20:52:24 +00:00
2018-08-25 15:47:52 +00:00
2018-07-26 16:45:25 +00:00
2017-10-31 00:07:04 +00:00
2018-10-20 21:13:57 +00:00
2018-06-16 23:47:59 +00:00
2017-10-31 00:07:04 +00:00