[Catalyst-commits] r8742 - Catalyst-Runtime/5.80/trunk/lib/Catalyst

andyg at dev.catalyst.perl.org andyg at dev.catalyst.perl.org
Fri Dec 5 08:33:15 GMT 2008


Author: andyg
Date: 2008-12-05 08:33:15 +0000 (Fri, 05 Dec 2008)
New Revision: 8742

Modified:
   Catalyst-Runtime/5.80/trunk/lib/Catalyst/Engine.pm
Log:
If write() is passed an undef value to write, just return 0.  Fixes a warning in the print() test

Modified: Catalyst-Runtime/5.80/trunk/lib/Catalyst/Engine.pm
===================================================================
--- Catalyst-Runtime/5.80/trunk/lib/Catalyst/Engine.pm	2008-12-05 08:30:48 UTC (rev 8741)
+++ Catalyst-Runtime/5.80/trunk/lib/Catalyst/Engine.pm	2008-12-05 08:33:15 UTC (rev 8742)
@@ -623,6 +623,8 @@
         $self->{_prepared_write} = 1;
     }
     
+    return 0 if !defined $buffer;
+    
     my $len   = length($buffer);
     my $wrote = syswrite STDOUT, $buffer;
     




More information about the Catalyst-commits mailing list