From: Vincent Pit Date: Sat, 2 May 2009 11:45:16 +0000 (+0200) Subject: Ignore the stack trace below Perl_runops* when generating perl suppressions X-Git-Tag: v1.02~4 X-Git-Url: http://git.vpit.fr/?a=commitdiff_plain;h=dd7e7df5cf3474dce1f29ee510b1a1659e6751e7;p=perl%2Fmodules%2FTest-Valgrind.git Ignore the stack trace below Perl_runops* when generating perl suppressions --- diff --git a/lib/Test/Valgrind/Command/Perl.pm b/lib/Test/Valgrind/Command/Perl.pm index 3ded74a..6e39550 100644 --- a/lib/Test/Valgrind/Command/Perl.pm +++ b/lib/Test/Valgrind/Command/Perl.pm @@ -166,6 +166,22 @@ sub suppressions_tag { return $self->{suppressions_tag}; } +sub filter { + my ($self, $session, $report) = @_; + + return $report if $report->is_diag + or not $report->isa('Test::Valgrind::Report::Suppressions'); + + my $data = $report->data; + $data =~ s/^[^\r\n]*\bPerl_runops_(?:standard|debug)\b.*//ms; + + $report->new( + id => $report->id, + kind => $report->kind, + data => $data, + ); +} + sub DESTROY { my ($self) = @_;