develooper Front page | perl.cvs.qpsmtpd | Postings from May 2007

[svn:qpsmtpd] r741 - in trunk: . lib/Qpsmtpd

From:
ask
Date:
May 17, 2007 15:28
Subject:
[svn:qpsmtpd] r741 - in trunk: . lib/Qpsmtpd
Message ID:
20070517222829.D1DB5CB9B8@x12.develooper.com
Author: ask
Date: Thu May 17 15:28:28 2007
New Revision: 741

Modified:
   trunk/Changes
   trunk/lib/Qpsmtpd/SMTP.pm

Log:
Fix logging when dropping a mail due to size (m. allan noah /
kitno455, issue #13)


Modified: trunk/Changes
==============================================================================
--- trunk/Changes	(original)
+++ trunk/Changes	Thu May 17 15:28:28 2007
@@ -2,6 +2,9 @@
 
   Added tests for the rcpt_ok plugin (Guy Hulbert, issue #4)
 
+  Fix logging when dropping a mail due to size (m. allan noah /
+  kitno455, issue #13)
+
   greylisting: fix db_dir configuration option so it actually works
   (kitno455, issue #6)
 

Modified: trunk/lib/Qpsmtpd/SMTP.pm
==============================================================================
--- trunk/lib/Qpsmtpd/SMTP.pm	(original)
+++ trunk/lib/Qpsmtpd/SMTP.pm	Thu May 17 15:28:28 2007
@@ -684,7 +684,8 @@
   }
 
   #$self->respond(550, $self->transaction->blocked),return 1 if ($self->transaction->blocked);
-  if ( $max_size and $size > $max_size ) {
+  if ($max_size and $size > $max_size) {
+      $self->log(LOGALERT, "Message too big: size: $size (max size: $max_size)");
       $self->respond(552, "Message too big!"); 
       $self->reset_transaction; # clean up after ourselves
       return 1;



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About