[Rt-commit] r7123 - in rt/branches/3.7-EXPERIMENTAL: .

ruz at bestpractical.com ruz at bestpractical.com
Fri Mar 2 21:23:12 EST 2007


Author: ruz
Date: Fri Mar  2 21:23:12 2007
New Revision: 7123

Modified:
   rt/branches/3.7-EXPERIMENTAL/   (props changed)
   rt/branches/3.7-EXPERIMENTAL/lib/RT/Attachment_Overlay.pm

Log:
 r4655 at cubic-pc:  cubic | 2007-03-03 04:20:55 +0300
 * use defined check on len as it could be zero
 * disable uninit warnings as content may be NULL


Modified: rt/branches/3.7-EXPERIMENTAL/lib/RT/Attachment_Overlay.pm
==============================================================================
--- rt/branches/3.7-EXPERIMENTAL/lib/RT/Attachment_Overlay.pm	(original)
+++ rt/branches/3.7-EXPERIMENTAL/lib/RT/Attachment_Overlay.pm	Fri Mar  2 21:23:12 2007
@@ -621,8 +621,9 @@
                         ) || $trx->CurrentUserHasRight('ShowTicket');
 
     my $len = $self->GetHeader('Content-Length');
-    unless ( $len ) {
+    unless ( defined $len ) {
         use bytes;
+        no warnings 'uninitialized';
         $len = length($self->Content);
         $self->SetHeader('Content-Length' => $len);
     }


More information about the Rt-commit mailing list