selftest: use a separate var for printing out sub parts of lines with \r
authorStefan Metzmacher <metze@samba.org>
Tue, 18 Mar 2008 08:36:29 +0000 (09:36 +0100)
committerStefan Metzmacher <metze@samba.org>
Tue, 18 Mar 2008 12:16:44 +0000 (13:16 +0100)
This restores the bahavior of the $_ variable in the code
that detects expected failures.

metze

source/selftest/Subunit.pm

index f8a7794aac4e83ba4e5d24bdb264eb566d4806d2..1c279437c88739bc573a12e62c1c1d252da33970 100644 (file)
@@ -17,6 +17,7 @@ sub parse_results($$$$$)
 
        while(1) {
                my $line = "";
+               my $subline = "";
                my $char = "";
                my $eof = 0;
                my $error = 0;
@@ -33,9 +34,10 @@ sub parse_results($$$$$)
                        }
 
                        $line .= $char;
+                       $subline .= $char;
                        if ($char eq "\r") {
-                               $msg_ops->output_msg($line);
-                               $line = "";
+                               $msg_ops->output_msg($subline);
+                               $subline = "";
                        }
                }