[svn:qpsmtpd] rev 400 - trunk/lib/Apache

[email protected] 27 Mar 2005 17:54:36 -0000
Newsgroups perl.cvs.qpsmtpd
Message-ID <[email protected]>
Author: msergeant
Date: Sun Mar 27 09:54:35 2005
New Revision: 400

Modified:
   trunk/lib/Apache/Qpsmtpd.pm
Log:
Fix for corruption problem under Apache


Modified: trunk/lib/Apache/Qpsmtpd.pm
==============================================================================
--- trunk/lib/Apache/Qpsmtpd.pm	(original)
+++ trunk/lib/Apache/Qpsmtpd.pm	Sun Mar 27 09:54:35 2005
@@ -112,11 +112,13 @@
         my $rc = $c->input_filters->get_brigade($bb, Apache::MODE_GETLINE);
         return if $rc == APR::EOF;
         die APR::Error::strerror($rc) unless $rc == APR::SUCCESS;
-        
+        my $data = '';
+
         while (!$bb->is_empty) {
             my $b = $bb->first;
             $b->remove;
-            $b->read(my $data);
+            $b->read(my $newdata);
+           $data .= $newdata;
             return $data if index($data, "\n") >= 0;
         }
     }