diff --git a/tools/test.pl b/tools/test.pl index 2e8ffd991..84164a5e9 100755 --- a/tools/test.pl +++ b/tools/test.pl @@ -406,7 +406,7 @@ sub random_number return if $min > $max; - return int ((rand ($max - $min)) + $min); + return int ((rand (($max + 1) - $min)) + $min); } sub random_bytes diff --git a/tools/test_modules/m00012.pm b/tools/test_modules/m00012.pm index 23261eaf0..816667e94 100644 --- a/tools/test_modules/m00012.pm +++ b/tools/test_modules/m00012.pm @@ -10,7 +10,7 @@ use warnings; use Digest::MD5 qw (md5_hex); -sub module_constraints { [[0, 256], [0, 256], [0, 55], [0, 55], [0, 55]] } +sub module_constraints { [[0, 256], [0, 32], [0, 55], [0, 32], [0, 55]] } sub module_generate_hash {