]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
runtests: provide nicer errormsg when protocol "dump" file is empty
authorDaniel Stenberg <daniel@haxx.se>
Wed, 8 Apr 2020 07:44:33 +0000 (09:44 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Wed, 8 Apr 2020 12:15:47 +0000 (14:15 +0200)
tests/runtests.pl

index 88a8b7f7fd32cd4a79da3e8c540292c64e6942d3..7957595444ef4266d9c7cb42fe6a0fb738ee962d 100755 (executable)
@@ -4122,6 +4122,13 @@ sub singletest {
             }
         }
 
+        if(($out[0] eq "") && $protstrip[0]) {
+            logmsg "\n $testnum: protocol FAILED!\n".
+                " There was no content at all in the file $SERVERIN.\n".
+                " Server glitch? Total curl failure?\n";
+            return $errorreturncode;
+        }
+
         $res = compare($testnum, $testname, "protocol", \@out, \@protstrip);
         if($res) {
             return $errorreturncode;