From 4d061dfa892aba187b5e237f52b7ab37e2a9acaf Mon Sep 17 00:00:00 2001 From: Christian Eisendle Date: Tue, 16 Feb 2016 22:03:57 +0100 Subject: [PATCH] Replace all occurances of CR in X-Spam-Status The hack for outlook (replacing CR in X-Spam-Status header) assumes that there is only a single occurance of CR. However, if spamassassin adds some more spam status information X-Spam-Status might be several lines long leading to multiple occurance of CR. This fix changes the substitute to a global subsititute, replacing all CRs in the X-SPam-Status header. --- plugins/spamassassin | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/spamassassin b/plugins/spamassassin index 5d1a0ce..cf8f8be 100644 --- a/plugins/spamassassin +++ b/plugins/spamassassin @@ -273,7 +273,7 @@ sub insert_spam_headers { if ($name eq 'X-Spam-Status') { $self->parse_spam_header($new_headers->{$name}); } - $new_headers->{$name} =~ s/\015//; # hack for outlook + $new_headers->{$name} =~ s/\015//g; # hack for outlook $self->_cleanup_spam_header($transaction, $name); $transaction->header->add($name, $new_headers->{$name}, 0); }