]> The Tcpdump Group git mirrors - tcpdump/commitdiff
do not warn about extra lines in stderr if there is a stderr file that was compared
authorMichael Richardson <[email protected]>
Wed, 18 Sep 2019 22:18:10 +0000 (18:18 -0400)
committerFrancois-Xavier Le Bail <[email protected]>
Tue, 24 Sep 2019 12:12:09 +0000 (14:12 +0200)
tests/TESTonce

index 07a682ac5afdc20745c6e72bd4c552b4317faa65..425abaab36d16f65f79bc30a74dba600e9de7845 100755 (executable)
@@ -87,7 +87,7 @@ else {
     open(ERRORRAW, "<" . $rawstderrlog);
     open(ERROROUT, ">" . $stderrlog);
     while(<ERRORRAW>) {
-        next if /^$/;  # blank lines are boring
+        next if /^\s*$/;  # blank lines are boring
         if(/^(reading from file )(.*)(,.*)$/) {
             my $filename = basename($2);
             print ERROROUT "${1}${filename}${3}\n";
@@ -123,7 +123,7 @@ else {
 
 if($r == 0) {
     my $stderrlog="";
-    if($linecount > 0) {
+    if($linecount > 0 && $errdiffstat != "-") {
         $stderrlog=sprintf("-- %d lines extra in stderr", $linecount);
     }
     if(!defined($ENV{"SKIPPASSED"})) {