X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=Debbugs%2FMIME.pm;h=bc47ca3a7b0a94e549fafd49dd473505fa3d7157;hb=b327c4b84c2024fca0a211e0cfd5e272281efb53;hp=640627651581826bf8bcce5570d8acb46085a3ce;hpb=5efa704a6ef44aca70afbcf0b784ca02c422257c;p=debbugs.git diff --git a/Debbugs/MIME.pm b/Debbugs/MIME.pm index 6406276..bc47ca3 100644 --- a/Debbugs/MIME.pm +++ b/Debbugs/MIME.pm @@ -229,9 +229,7 @@ sub convert_to_utf8 { return $data if $charset eq 'raw' or is_utf8($data,1); my $result; eval { - # this encode/decode madness is to make sure that the data - # really is valid utf8 and that the is_utf8 flag is off. - $result = encode("utf8",decode($charset,$data)) + $result = decode($charset,$data); }; if ($@) { warn "Unable to decode charset; '$charset' and '$data': $@";