From: Vincent Pit Date: Sat, 19 Sep 2009 23:36:13 +0000 (+0200) Subject: With protocol v4, leakedbytes and leakedblocks are found in the xwhat node X-Git-Tag: v1.10~6 X-Git-Url: http://git.vpit.fr/?p=perl%2Fmodules%2FTest-Valgrind.git;a=commitdiff_plain;h=15ef67081abedb9919e112ca5a7e8b6e7fc9c6d2 With protocol v4, leakedbytes and leakedblocks are found in the xwhat node --- diff --git a/lib/Test/Valgrind/Parser/XML/Twig.pm b/lib/Test/Valgrind/Parser/XML/Twig.pm index 318e2db..29d0f96 100644 --- a/lib/Test/Valgrind/Parser/XML/Twig.pm +++ b/lib/Test/Valgrind/Parser/XML/Twig.pm @@ -94,7 +94,7 @@ sub handle_error { $node->kid('stack')->children('frame') ]; for (qw/leakedbytes leakedblocks/) { - my $kid = $node->first_child($_); + my $kid = ($xwhat || $node)->first_child($_); next unless $kid; $data->{$_} = int $kid->text; }