## ", and doesn't have a Return-Path. Fix that up so spamassassin
## is happy.
$message =~
- s{^(Received: at \S+\ by \S+;[^\n]+\n)(From (\S+) [^\n]+\n)}
- {${1}Return-Path: $3\n$2};
+ s{^(Received: \(at \S+\) by \S+;[^\n]+\n)(From (\S+) [^\n]+\n)}
+ {${2}Return-path: $3\n$1};
return $message;
}
die "Unable to open bug log for $bug_num";
my %seen_msgids;
while (my $record = $log->read_record()) {
- next if $record->{type} eq 'html';
- next if $record->{type} eq 'autocheck';
+ next unless $record->{type} eq 'incoming-recv';
my ($msg_id) = record_regex($record,
qr/^Message-Id:\s+<(.+)>/mi);
next unless defined $msg_id;