]> git.vpit.fr Git - perl/modules/Test-Valgrind.git/commitdiff
Ignore the stack trace below Perl_runops* when generating perl suppressions
authorVincent Pit <vince@profvince.com>
Sat, 2 May 2009 11:45:16 +0000 (13:45 +0200)
committerVincent Pit <vince@profvince.com>
Sat, 2 May 2009 11:45:16 +0000 (13:45 +0200)
lib/Test/Valgrind/Command/Perl.pm

index 3ded74a587c7ebbbb2f3cf61a4200a3a72b1b493..6e39550e0869264ffa1fb0d14c3c4548910a8bf0 100644 (file)
@@ -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) = @_;