From 0a713139f6a0ee8b55b8bb9839059c5b5e4d99a1 Mon Sep 17 00:00:00 2001 From: Yang Tse Date: Mon, 18 Jan 2010 17:47:01 +0000 Subject: fix warnings --- tests/runtests.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/runtests.pl b/tests/runtests.pl index 06eb01c43..2b74f6b47 100755 --- a/tests/runtests.pl +++ b/tests/runtests.pl @@ -728,7 +728,7 @@ sub verifyhttp { sub verifyftp { my ($proto, $ipvnum, $idnum, $ip, $port) = @_; my $server = servername_id($proto, $ipvnum, $idnum); - my $pid; + my $pid = 0; my $time=time(); my $extra=""; if($proto eq "ftps") { @@ -755,7 +755,7 @@ sub verifyftp { last; } } - if($pid <= 0 && $data[0]) { + if($pid <= 0 && @data && $data[0]) { # this is not a known server logmsg "RUN: Unknown server on our ". uc($proto) ." port: $port\n"; return 0; -- cgit v1.2.3