diff options
author | Daniel Stenberg <daniel@haxx.se> | 2017-05-08 10:08:48 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2017-05-08 10:09:06 +0200 |
commit | e3f84efc32d6b01a605c93b39668653049c15188 (patch) | |
tree | f1a0887c2768e14f550d414bec1f9b2f154ff0b1 | |
parent | e2b394106d543c4615a60795b7fdce04bd4e5090 (diff) |
runtests: fix "use of undefined value" warning in -R handling
-rwxr-xr-x | tests/runtests.pl | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/runtests.pl b/tests/runtests.pl index 48e26142f..d20383ae8 100755 --- a/tests/runtests.pl +++ b/tests/runtests.pl @@ -5179,7 +5179,11 @@ if($scrambleorder) { # scramble the order of the test cases my @rand; while($TESTCASES) { - my @all = split(/ /, $TESTCASES); + my @all = split(/ +/, $TESTCASES); + if(!$all[0]) { + # if the first is blank, shift away it + shift @all; + } my $r = rand @all; push @rand, $all[$r]; $all[$r]=""; |