Commit 20df5235 authored by mkanat%bugzilla.org's avatar mkanat%bugzilla.org

Bug 357526: buglist.cgi doesn't specify encoding as UTF-8 when the rest of Bugzilla does

Patch By John Beranek <john@redux.org.uk> r=mkanat, a=justdave
parent 89edfad4
...@@ -166,7 +166,19 @@ sub multipart_init { ...@@ -166,7 +166,19 @@ sub multipart_init {
# Have to add the cookies in. # Have to add the cookies in.
sub multipart_start { sub multipart_start {
my $self = shift; my $self = shift;
my $headers = $self->SUPER::multipart_start(@_);
my %args = @_;
# CGI.pm::multipart_start doesn't accept a -charset parameter, so
# we do it ourselves here
if (defined $args{-charset} && defined $args{-type}) {
# Remove any existing charset specifier
$args{-type} =~ s/;.*$//;
# and add the specified one
$args{-type} .= "; charset=$args{-charset}";
}
my $headers = $self->SUPER::multipart_start(%args);
# Eliminate the one extra CRLF at the end. # Eliminate the one extra CRLF at the end.
$headers =~ s/$CGI::CRLF$//; $headers =~ s/$CGI::CRLF$//;
# Add the cookies. We have to do it this way instead of # Add the cookies. We have to do it this way instead of
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment