compress regex for headers

This commit is contained in:
mischa 2022-08-20 18:25:28 +00:00
parent 0d644ac2bf
commit ad41b4cd4d

View File

@ -88,15 +88,7 @@ while (my $line = <>) {
my ($stream, $version, $timestamp, $subsystem, $event, $sid, $token, $data) = split /\|/, $line;
if ($line =~ m/data-line/) {
if (!$data) { $data = ""; }
if ($data =~ m/^precedence:\s+(bulk|list|junk)/i) {
$ooo{$sid} = 0;
dolog($fh, "$sid header skip $data", $opt_l);
}
if ($data =~ m/^list-(help|id|owner|post|subscribe|unsubscribe):.*/i) {
$ooo{$sid} = 0;
dolog($fh, "$sid header skip $data", $opt_l);
}
if ($data =~ m/^x-loop:\s+opensmtpd\ admin\ virtual\ vacation/i) {
if ($data =~ m/^(precedence:\s+(bulk|list|junk)|list-(help|id|owner|post|subscribe|unsubscribe)|x-loop:\s+opensmtpd\ admin)/i) {
$ooo{$sid} = 0;
dolog($fh, "$sid header skip $data", $opt_l);
}