# the path to the script that analyzes the memory debug output file:
my $memanalyze="./memanalyze.pl";
-my $checkstunnel = checkcmd("stunnel");
-my $checkvalgrind = checkcmd("valgrind");
+my $stunnel = checkcmd("stunnel");
+my $valgrind = checkcmd("valgrind");
my $ssl_version; # set if libcurl is built with SSL support
my %skipped; # skipped{reason}=counter, reasons for skip
my @teststat; # teststat[testnum]=reason, reasons for skip
-if($checkvalgrind) {
+if($valgrind) {
# we have found valgrind on the host, use it
# perhaps we should verify that valgrind works before we actually use it?
my $RUNNING;
my $pid=checkserver($HTTPSPIDFILE );
+ if(!$stunnel) {
+ return 0;
+ }
+
if($pid > 0) {
# kill previous stunnel!
if($verbose) {
}
my $flag=$debugprotocol?"-v ":"";
- my $cmd="$perl $srcdir/httpsserver.pl $flag -d $srcdir -r $HOSTPORT $HTTPSPORT &";
+ my $cmd="$perl $srcdir/httpsserver.pl $flag -s \"$stunnel\" -d $srcdir -r $HOSTPORT $HTTPSPORT &";
system($cmd);
if($verbose) {
print "CMD: $cmd\n";
my $RUNNING;
my $pid=checkserver($FTPSPIDFILE );
+ if(!$stunnel) {
+ return 0;
+ }
+
if($pid > 0) {
# kill previous stunnel!
if($verbose) {
}
my $flag=$debugprotocol?"-v ":"";
- my $cmd="$perl $srcdir/ftpsserver.pl $flag -d $srcdir -r $FTPPORT $FTPSPORT &";
+ my $cmd="$perl $srcdir/ftpsserver.pl $flag -s \"$stunnel\" -d $srcdir -r $FTPPORT $FTPSPORT &";
system($cmd);
if($verbose) {
print "CMD: $cmd\n";
"* Host: $hostname",
"* System: $hosttype";
- printf("* Server SSL: %s\n", $checkstunnel?"ON":"OFF");
+ printf("* Server SSL: %s\n", $stunnel?"ON":"OFF");
printf("* libcurl SSL: %s\n", $ssl_version?"ON":"OFF");
printf("* libcurl debug: %s\n", $curl_debug?"ON":"OFF");
- printf("* valgrind: %s\n", $checkvalgrind?"ON":"OFF");
+ printf("* valgrind: %s\n", $valgrind?"ON":"OFF");
print "***************************************** \n";
}
$cmdargs .= " <$stdinfile";
}
- if($checkvalgrind) {
+ if($valgrind) {
$cmdargs .= " 3>log/valgrind$testnum";
}
my $CMDLINE;
}
else {
$res = system("$CMDLINE");
- $res /= 256;
+ my $signal_num = $res & 127;
+ my $dumped_core = $res & 128;
+
+ if(!$anyway && ($signal_num || $dumped_core)) {
+ $res = 1000;
+ }
+ else {
+ $res /= 256;
+ }
}
# remove the special FTP command file after each test!
}
}
elsif($what eq "ftps") {
- if(!$checkstunnel || !$ssl_version) {
+ if(!$stunnel || !$ssl_version) {
# we can't run https tests without stunnel
# or if libcurl is SSL-less
return 1;
# we support it but have no server!
}
elsif($what eq "https") {
- if(!$checkstunnel || !$ssl_version) {
+ if(!$stunnel || !$ssl_version) {
# we can't run https tests without stunnel
# or if libcurl is SSL-less
return 1;