procmail
[Top] [All Lists]

Re: How to excluding the newline in Headers scan?

2002-05-02 11:56:35
      Thanks David, it is helped me.  I understand the procmail doesn't
      delete the "\n", it just ignores it.  May I ask to add the option
      to see the "\n" into the Wish List?   Sometimes one need work on the
      Subject field, in this case we want to be more specific.

The '.' metacharacter does not match a newline.  The only case where
newlines are 'ignored' in the headers is where a single header has been
split across several lines.  Newlines between different headers are NOT
ignored.

I realise that I explained that badly :-)

Consider a mail that contains:

  From: Udi Mottelo
        <uuddii(_at_)eng(_dot_)tau(_dot_)ac(_dot_)il>
  Subject: Re: How to excluding the newline in Headers scan?

where the 'From:' header is split over 2 lines.

  * ^From:.*ac\.il>

will match because procmail knows that those first two lines are really
part of the same header line.  But

  * ^From:.*scan

will not match because the newline before the 'Subject:' line is NOT
ignored and '.' will not match a newline.

Hope that helps, but I'm not sure I was at all clear! :-/
Martin
-- 
Martin McCarthy                 /</    http://procmail.non-prophet.org
    `Procmail Companion'        \>\
     Addison Wesley             /</                  PGP key available
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>