spamassassin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sid...@apache.org
Subject svn commit: r474216 - /spamassassin/trunk/lib/Mail/SpamAssassin/Plugin/DKIM.pm
Date Mon, 13 Nov 2006 09:36:54 GMT
Author: sidney
Date: Mon Nov 13 01:36:53 2006
New Revision: 474216

URL: http://svn.apache.org/viewvc?view=rev&rev=474216
Log:
bug 5179: DKIM plugin was adding blank line after headers when they use DOS style newlines

Modified:
    spamassassin/trunk/lib/Mail/SpamAssassin/Plugin/DKIM.pm

Modified: spamassassin/trunk/lib/Mail/SpamAssassin/Plugin/DKIM.pm
URL: http://svn.apache.org/viewvc/spamassassin/trunk/lib/Mail/SpamAssassin/Plugin/DKIM.pm?view=diff&rev=474216&r1=474215&r2=474216
==============================================================================
--- spamassassin/trunk/lib/Mail/SpamAssassin/Plugin/DKIM.pm (original)
+++ spamassassin/trunk/lib/Mail/SpamAssassin/Plugin/DKIM.pm Mon Nov 13 01:36:53 2006
@@ -256,8 +256,8 @@
   }
 
   # headers, line-by-line with \r\n endings, as per Mail::DKIM API
-  foreach my $line (split(/\n/s, $header)) {
-    $line =~ s/\r?$/\r\n/s;         # ensure \r\n ending
+  foreach my $line (split(/\r?\n/s, $header)) {  # split lines, deleting endings and final
empty line
+    $line =~ s/$/\r\n/s;  # add back a standard \r\n ending
     $message->PRINT($line);
   }
   $message->PRINT("\r\n");



Mime
View raw message