]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 387860 รข\80\93 Subject lines in mails may contain mangled multi-byte characters.
authorwurblzap%gmail.com <>
Thu, 2 Aug 2007 12:20:57 +0000 (12:20 +0000)
committerwurblzap%gmail.com <>
Thu, 2 Aug 2007 12:20:57 +0000 (12:20 +0000)
Patch by Ilya Slobodin <islobodin@yandex.ru>,
r=Wurblzap, a=mkanat

Bugzilla/Mailer.pm

index ab54ecfea9ba9d9a55c0eb38dfbdb2b9b20b1d20..b4b2f320d959374d3ca63c79d62938bfd5280337 100644 (file)
@@ -66,6 +66,7 @@ sub MessageToMTA {
     # Encode the headers correctly in quoted-printable
     foreach my $header qw(From To Cc Reply-To Sender Errors-To Subject) {
         if (my $value = $email->header($header)) {
+            $value = Encode::decode("UTF-8", $value) if Bugzilla->params->{'utf8'};
             my $encoded = encode('MIME-Q', $value);
             $email->header_set($header, $encoded);
         }