[Rt-commit] r12822 - in rt/branches/3.8-TESTING/share/html: . Ticket/Graphs/Elements

sunnavy at bestpractical.com sunnavy at bestpractical.com
Mon Jun 2 18:29:19 EDT 2008


Author: sunnavy
Date: Mon Jun  2 18:29:16 2008
New Revision: 12822

Modified:
   rt/branches/3.8-TESTING/share/html/Ticket/Graphs/Elements/ShowGraph
   rt/branches/3.8-TESTING/share/html/Ticket/Graphs/dhandler
   rt/branches/3.8-TESTING/share/html/autohandler

Log:
wrap some methods of GraphViz object to get rid of FILENO error from FCGI

Modified: rt/branches/3.8-TESTING/share/html/Ticket/Graphs/Elements/ShowGraph
==============================================================================
--- rt/branches/3.8-TESTING/share/html/Ticket/Graphs/Elements/ShowGraph	(original)
+++ rt/branches/3.8-TESTING/share/html/Ticket/Graphs/Elements/ShowGraph	Mon Jun  2 18:29:16 2008
@@ -46,7 +46,7 @@
 %# 
 %# END BPS TAGGED BLOCK }}}
 <div><img src="<% $RT::WebPath %>/Ticket/Graphs/<% $Type %>/<% $id %>?<% $m->comp('/Elements/QueryString', %ARGS) %>" usemap="#<% $graph->{'NAME'} || 'test' %>" style="border: none" />
-<% Encode::decode_utf8( $graph->as_cmapx ) |n %>
+<% safe_run_child { Encode::decode_utf8( $graph->as_cmapx ) } |n %>
 </div>
 <& ShowLegends, %ARGS, Ticket => $ticket &>
 <%ARGS>

Modified: rt/branches/3.8-TESTING/share/html/Ticket/Graphs/dhandler
==============================================================================
--- rt/branches/3.8-TESTING/share/html/Ticket/Graphs/dhandler	(original)
+++ rt/branches/3.8-TESTING/share/html/Ticket/Graphs/dhandler	Mon Jun  2 18:29:16 2008
@@ -71,7 +71,11 @@
 
 $r->content_type( 'image/png' );
 $m->clear_buffer;
-$graph->as_png( sub { $m->out( shift ) } );
+
+my $png;
+safe_run_child { $graph->as_png(\$png) };
+$m->out( $png );
+
 $m->abort;
 
 </%INIT>

Modified: rt/branches/3.8-TESTING/share/html/autohandler
==============================================================================
--- rt/branches/3.8-TESTING/share/html/autohandler	(original)
+++ rt/branches/3.8-TESTING/share/html/autohandler	Mon Jun  2 18:29:16 2008
@@ -46,6 +46,8 @@
 %# 
 %# END BPS TAGGED BLOCK }}}
 <%INIT>
+use RT::Util;
+
 if (RT->InstallMode) {
   if  ( $m->base_comp->path =~ RT->Config->Get('WebNoAuthRegex') ) {
     $m->call_next();


More information about the Rt-commit mailing list