From de46c7042907923c9b88af67849dddab9a5101ba Mon Sep 17 00:00:00 2001 From: =?utf8?q?Sven=20Sch=C3=B6ling?= Date: Wed, 11 Mar 2009 15:42:30 +0000 Subject: [PATCH] =?utf8?q?sch=C3=B6ner=20so.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- SL/Mailer.pm | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/SL/Mailer.pm b/SL/Mailer.pm index 1cf519b60..3cf205364 100644 --- a/SL/Mailer.pm +++ b/SL/Mailer.pm @@ -193,16 +193,15 @@ $self->{message} return "$attachment : $!"; } - print OUT qq|--${boundary} -Content-Type: $application/$self->{format}; name="$filename"; |; - # only set charset for attachements of type text. every other type should not have this field # refer to bug 883 for detailed information - if ($application eq 'text' && $self->{charset}) { - print OUT qq|charset="$self->{charset}" |; + my $attachment_charset; + if (lc $application eq 'text' && $self->{charset}) { + $attachment_charset = qq|; charset="$self->{charset}" |; } - print OUT qq| + print OUT qq|--${boundary} +Content-Type: $application/$self->{format}; name="$filename"$attachment_charset Content-Transfer-Encoding: BASE64 Content-Disposition: attachment; filename="$filename"\n\n|; -- 2.20.1