Commit Graph

7 Commits (develop)

Author SHA1 Message Date
Erik Auerswald 54e6f838c3 also apply generator limit to use with CIDR
As described in GH issue #299, the MAX_GENERATE+1 limit is only
applied when using an address range, not when using CIDR.  This
commit changes this to always honor the generator limit.

* refactor target address generation to use the same new function
  for both range and CIDR notation
* check the limit for addresses to generate in the new function
* document the generator limit in "fping --help" output
* document the generator limit in the fping man page
* test that the address generation limit applies when using CIDR
  notation
4 months ago
Erik Auerswald ef74f642d1 Test edge cases of -f and -g
* -f with non-existing file
* -f with input file containing comment and empty line
* -g with non-numeric address in "CIDR" format
* -g with one non-numeric address in start resp. end position
* -g with one IPv6 address in start resp. end position
9 months ago
Erik Auerswald ccc0cdfdd7 Test that -g does not accept IPv6 10 months ago
Erik Auerswald 2fa4f61079 Test edge case behavior of "fping -g"
* wrong number or kind of arguments fails and prints usage;
* an empty range silently pings nothing and fping returns 1;
* a too large range fails with an error message;
* a zero CIDR prefix length fails with an error message.
10 months ago
David Schweikert 98269fb83e unification work 8 years ago
Martin Topholm 3838e90154 Added tests -g for long prefixes
Expanded tests for -g option to hopefully cover both long prefixes and
too long prefixes.
8 years ago
David Schweikert 4d733db14a rename tests 10 years ago