ZMailer default MIME::WordDecoder

Leonardo Helman mailscanner at lists.com.ar
Wed May 31 20:48:22 IST 2006


Hi, I have this little patch to ZMailer.pm (only), it was 
added to every other mta code before (I'm trying to catch up)

I've added the 
   MIME::WordDecoder->default->handler('*' => \&MailScanner::Message::WordDecoderKeep7Bit);


Question:
This code is also in Messages.pm (3 or 4 times) and in the MTA's
Is there a reason for that code to be executed several times each
mail instead of being (for instance) in WorkForHours or 
MailScanner::Sendmail::initialise or *::initialise?

It's not a heavy call or something, but it looks like setting a
default handler for all the program would be
all right, just a little more efficient. 
That if SA or someone don't change it.



==============================================================================
--- MailScanner.ORIG/lib/MailScanner/ZMailer.pm	2006-05-30 09:22:08.000000000 -0300
+++ MailScanner/lib/MailScanner/ZMailer.pm	2006-05-30 09:22:47.000000000 -0300
@@ -69,6 +69,8 @@
   MailScanner::Config::Default('sendmail2',
                                MailScanner::Config::Value('sendmail'));
   $UnsortedBatchesLeft = 0; # Disable queue-clearing mode
+  # The default action is to WARN, and return 1
+  MIME::WordDecoder->default->handler('*' => \&MailScanner::Message::WordDecoderKeep7Bit);
 }
 
 # Constructor.
==============================================================================


I didn't have the time to try our latest additions to ZMailer code.


Saludos
--  
Leonardo Helman
Pert Consultores
Argentina


More information about the MailScanner mailing list