summaryrefslogtreecommitdiffstats
path: root/sbin/ping
diff options
context:
space:
mode:
authorglebius <glebius@FreeBSD.org>2016-03-11 21:06:17 +0000
committerglebius <glebius@FreeBSD.org>2016-03-11 21:06:17 +0000
commit5b04e75f255bde5223c27fde853cd9d15d9841c5 (patch)
treeaccaddf236b9cbb7a0508d8faa7b3b54019ec2af /sbin/ping
parentd652802e2431dec69e6586378b0a804c9aa5d4f7 (diff)
downloadFreeBSD-src-5b04e75f255bde5223c27fde853cd9d15d9841c5.zip
FreeBSD-src-5b04e75f255bde5223c27fde853cd9d15d9841c5.tar.gz
Allow minimum and maximum sweep size be the same.
Submitted by: maxim
Diffstat (limited to 'sbin/ping')
-rw-r--r--sbin/ping/ping.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sbin/ping/ping.c b/sbin/ping/ping.c
index 1fc1963..a5f8602 100644
--- a/sbin/ping/ping.c
+++ b/sbin/ping/ping.c
@@ -793,8 +793,8 @@ main(int argc, char *const *argv)
}
#endif
if (sweepmax) {
- if (sweepmin >= sweepmax)
- errx(EX_USAGE, "Maximum packet size must be greater than the minimum packet size");
+ if (sweepmin > sweepmax)
+ errx(EX_USAGE, "Maximum packet size must be no less than the minimum packet size");
if (datalen != DEFDATALEN)
errx(EX_USAGE, "Packet size and ping sweep are mutually exclusive");
OpenPOWER on IntegriCloud