]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 464992: Binary attachments, graphical reports and new charts are not displayed...
authorlpsolit%gmail.com <>
Thu, 15 Jan 2009 01:13:50 +0000 (01:13 +0000)
committerlpsolit%gmail.com <>
Thu, 15 Jan 2009 01:13:50 +0000 (01:13 +0000)
Bugzilla/Util.pm
chart.cgi
report.cgi

index 376bcf6cdbbf5fec8fa8c5de8df049791a67f657..8666b18ffcde8bf398757b9d4c74931f59f6b946 100644 (file)
@@ -623,7 +623,7 @@ sub get_netaddr {
 
 sub disable_utf8 {
     if (Bugzilla->params->{'utf8'}) {
-        binmode STDOUT, ':raw'; # Turn off UTF8 encoding.
+        binmode STDOUT, ':bytes'; # Turn off UTF8 encoding.
     }
 }
 
index 25d5b446decb5cae211f8a92bf8be2f520cf5283..ab145c42a941ec80ef0a4965975a51562fdce69d 100755 (executable)
--- a/chart.cgi
+++ b/chart.cgi
@@ -282,6 +282,8 @@ sub plot {
     }
 
     print $cgi->header($format->{'ctype'});
+    disable_utf8() if ($format->{'ctype'} =~ /^image\//);
+
     $template->process($format->{'template'}, $vars)
       || ThrowTemplateError($template->error());
 }
index c84ed6208ed0842bdd87cbfaba3f789ccd6e5f34..fd2f28943af469a4e5031a79007e9265b162faf3 100755 (executable)
@@ -328,6 +328,8 @@ if ($cgi->param('debug')) {
 # All formats point to the same section of the documentation.
 $vars->{'doc_section'} = 'reporting.html#reports';
 
+disable_utf8() if ($format->{'ctype'} =~ /^image\//);
+
 $template->process("$format->{'template'}", $vars)
   || ThrowTemplateError($template->error());