ZMailer update patch

Mariano Absatz mailscanner at LISTS.COM.AR
Thu May 29 14:52:55 IST 2003


Well... it is a mistake... I should add a '[' or erase the ']' (both would
work)... but grep-ing around I found that the TFileRegexp attribute is
initialised in every version of MailScanner::Sendmail... but _NEVER_
referenced... seems like 3.x inherited and actually unnecessary...

Quick and dirty you could:

for i in Sendmail Exim Zmailer Postfix
do
  echo cleaning up $i.pm
  mv $i.pm $i.pm.SAVE
  perl -n -e 'print unless /TFileRegexp/;' $i.pm.SAVE > $i.pm
done

:-)

But checkin further... the _ONLY_ xxxFileRegexp that is actually used is
HFileRegexp in Sendmail and Exim and its cousin HDFileRegexp in ZMailer and
Postfix.

TFileRegexp and QueueFileRegexp are _NEVER_ referenced... what's more, I went
back as far as 4.05 and this was true back then...

So I'm cleaning up ZMailer.pm and leave to you the other three :-)

The new ZMailer.pm is attached.


El 28 May 2003 a las 21:32, Julian Field escribió:

> On line 82 of ZMailer.pm, do you really mean
> $this->{TFileRegexp} = '^tf-' . $$ . '-(\\d]+)$';
> and not
> $this->{TFileRegexp} = '^tf-' . $$ . '-([\\d]+)$';
>
> Possible missing '[' ?
>
> At 20:43 28/05/2003, you wrote:
> >El 27 May 2003 a las 11:21, Julian Field escribió:
> >
> > > Can you mail me the patch please? (Or just mail me up to date ZM*.pm files,
> > > that would be easier)
> >Find it enclosed in this message.
> >
> > >
> > > At 16:47 26/05/2003, you wrote:
> > > >Hi Julian,
> > > >
> > > >I did a small modification to the zmailer code in MailScanner.
> > > >
> > > >ZMailer's router wants its queue file names to be the files' inode
> > number. As
> > > >MailScanner creates a new queue file (in order to put the new headers),
> > > >MailScanner::ZMailer::HDOutFileName does a 'stat' of the new file to
> > find out
> > > >the new file name, and then MailScanner::ZMDiskStore::WriteHeader does a
> > > >rename to this new file.
> > > >
> > > >This is working OK from the start, but there is no logging of such a
> > renaming
> > > >happening, and the new file name (which is used as message id) is never
> > > >recorded.
> > > >
> > > >I did a very small patch that doesn't modify outside behaviour, but
> > changes a
> > > >little the way where the new filename is built, which allows me to do a
> > > >MailScanner::Log::InfoLog for every message, so everyone can track the
> > > >messages thru smtpserver/mailscanner/router _and_ I also add a new
> > attribute
> > > >to the message object with this ($message->{newid}) so I can have it at my
> > > >"Always Looked Up Last" routine...
> > > >
> > > >It is now in production and working fine.
> >
> >--
> >Mariano Absatz
> >El Baby
> >----------------------------------------------------------
> >Unix is very simple, but it takes a genius to understand the simplicity.
> >                      -- Dennis Ritchie
> >
> >
>
> --
> Julian Field
> www.MailScanner.info
> Professional Support Services at www.MailScanner.biz
> MailScanner thanks transtec Computers for their support


--
Mariano Absatz
El Baby
----------------------------------------------------------
Conjecture: All odd numbers are prime.
    Mathematician's Proof:
        3 is prime.  5 is prime.  7 is prime.  By induction, all
        odd numbers are prime.
    Physicist's Proof:
        3 is prime.  5 is prime.  7 is prime.  9 is experimental
        error.  11 is prime.  13 is prime ...
    Engineer's Proof:
        3 is prime.  5 is prime.  7 is prime.  9 is prime.
        11 is prime.  13 is prime ...
    Computer Scientists's Proof:
        3 is prime.  3 is prime.  3 is prime.  3 is prime...


-------------- next part --------------
A non-text attachment was scrubbed...
Name: ZMailer.pm
Type: application/octet-stream
Size: 25573 bytes
Desc: not available
Url : http://lists.mailscanner.info/pipermail/mailscanner/attachments/20030529/9d61330d/ZMailer.obj


More information about the MailScanner mailing list