procmail
[Top] [All Lists]

Re: [Announcem.] Softlabs AntiVirus 0.5.5 has been released on SourceForge.net

2004-03-22 15:33:11
Robert Allerstorfer wrote:
I am aware that MATCH will not be unset after its assignment, but my
feeling has been (and still is) that it *will* be before procmail
comes to a new \/.

No, if there's no actual match, MATCH retains its value. (You only had
matching expressions in your example, that's why you didn't notice.)
Try this ...

  :0
  * ^Subject: \/foo
  { } 

  match1=$MATCH

  :0
  * ^Subject: \/bar
  { }

  match2=$MATCH

... with a message with subject "foo":

  Assigning "MATCH="
  Matched "foo"
  Match on "^Subject: \/foo"
  Assigning "match1=foo"
  No match on "^Subject: \/bar"
  Assigning "match2=foo"

The "foo" from the first recipe remains in MATCH even though there's a
\/ in the second one.

/HW

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail