Was reading over remove_spamassassin_markup to see what it does. Was
wondering about this
section of code:

  foreach my $header ( keys  %{$self->{conf}->{rewrite_header}} ) {
    dbg ("Removing markup in $header");
    if ($header eq 'Subject') {
      my $tag = $self->{conf}->{rewrite_header}->{'Subject'};
      $tag = quotemeta($tag);
      $tag =~ s/_HITS_/\\d{2}\\.\\d{2}/g;
      $tag =~ s/_SCORE_/\\d{2}\\.\\d{2}/g;
      $tag =~ s/_REQD_/\\d{2}\\.\\d{2}/g;
      1 while $hdrs =~ s/^Subject: ${tag} /Subject: /gm;
    } else {
      $hdrs =~ s/^(${header}: .*?)\t\([^)]\)$/$1/gm;
    }
  }

In particular, this line:
      $hdrs =~ s/^(${header}: .*?)\t\([^)]\)$/$1/gm;
It looks like it is processing the headers designated for
rewrite and removing <tab>(...) at the end of the line,
where ... means anything inside the parens?  But I think the
pattern needs iteration also: [^)]*?  perhaps?


Reply via email to