Alexandre Julliard : winetest: Add the report tag to the error message on parsing errors.
Alexandre Julliard
julliard at wine.codeweavers.com
Fri Mar 18 03:33:25 CDT 2016
Module: tools
Branch: master
Commit: 88a3af5aa052475067a37cf2bc6cbc67b963223b
URL: http://source.winehq.org/git/tools.git/?a=commit;h=88a3af5aa052475067a37cf2bc6cbc67b963223b
Author: Alexandre Julliard <julliard at winehq.org>
Date: Thu Mar 17 23:55:08 2016 +0900
winetest: Add the report tag to the error message on parsing errors.
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
winetest/dissect | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/winetest/dissect b/winetest/dissect
index 62cd997..2f2faa1 100755
--- a/winetest/dissect
+++ b/winetest/dissect
@@ -55,7 +55,7 @@ use Errno qw/ENOTEMPTY/;
$ENV{GIT_DIR} = $gitdir;
-my ($report, $tmpdir);
+my ($report, $tmpdir, $tag);
sub mydie(@) {
my $errdir = tempdir ("errXXXXX", DIR => $queuedir);
@@ -63,12 +63,13 @@ sub mydie(@) {
print STDERR "$name0:error: unable to rename '$tmpdir' to '$errdir': $!\n";
exit 3;
}
+ my $label = substr($tag,1) || "???";
if (open ERR, ">$errdir/error")
{
- print ERR "$name0:error:$errdir: ", @_;
+ print ERR "$label: ", @_;
close ERR;
}
- print STDERR "$name0:error:$errdir: ", @_;
+ print STDERR "$name0:error:$label: ", @_;
exit 1;
}
@@ -112,7 +113,7 @@ $_ = <IN>;
if (/^Archive: /) { $_ = <IN>; } # ignore Archive header
/^Tag: ([-.0-9a-zA-Z]*)\r?$/ or mydie "no tag line: $_";
-my $tag = $1 eq ""?"":"_$1";
+$tag = $1 eq ""?"":"_$1";
$_ = <IN>;
/^Build info:\r?$/ or mydie "no Build info header: $_";
More information about the wine-cvs
mailing list