From: Dan Fandrich Date: Mon, 17 Apr 2023 23:57:17 +0000 (-0700) Subject: [PATCH] runtests: don't try to stop stunnel before trying again X-Git-Tag: archive/raspbian/7.88.1-10+rpi1+deb12u12^2~32 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=14d0a7f6f372d1d69bce10bf26931ca720c867e9;p=curl.git [PATCH] runtests: don't try to stop stunnel before trying again Calling stopserver() before retrying stunnel due to an error would stop the dependent server (such as HTTP) meaning stunnel would have nothing to talk to when it came up. Don't try to force a stop when it didn't actually start. Also, don't mark the server as bad for future use when it starts up on a retry. Reported-by: eaglegai at github Tested-by: eaglegai at github Fixes #10976 Backported by: Aquila Macedo Costa . Changes: - Apply the changes to `runtests.pl` instead of `servers.pm`, as `servers.pm` does not exist in this version of bookworm. Gbp-Pq: Name dont-stop-stunnel-before-retry.patch --- diff --git a/tests/runtests.pl b/tests/runtests.pl index c4c7717c..7ac9de2d 100755 --- a/tests/runtests.pl +++ b/tests/runtests.pl @@ -1837,12 +1837,15 @@ sub runhttpsserver { if($httpspid <= 0 || !pidexists($httpspid)) { # it is NOT alive - stopserver($server, "$pid2"); + # don't call stopserver since that will also kill the dependent + # server that has already been started properly displaylogs($testnumcheck); $doesntrun{$pidfile} = 1; $httpspid = $pid2 = 0; next; } + + $doesntrun{$pidfile} = 0; # we have a server! if($verbose) { logmsg "RUN: $srvrname server is PID $httpspid port $port\n";