procmail
[Top] [All Lists]

Re: Matching two or more spaces

1996-01-31 12:48:38
Philip Guenther <guenther(_at_)gac(_dot_)edu> wrote:
Jim Osborn <jimo(_at_)eskimo(_dot_)com> writes:
     GETTING=$MATCH
Assigning GETTING=digest  98

     :0
     * GETTING ?? digest[    ]+\/.*
Assigning MATCH=
Matched ""

For speed reasons, procmail does minimal matching on the left hand side
of the \/.  This forces you to use a regexp like:

* GETTING ?? digest[   ]+\/[^  ].*

Each bracket contains both a space and a tab.  The second forces the
match to start on the first non-whitespace, thus forcing the previous
'+' operator to eat all the whitespace instead of just one.

All very true, nevertheless, logic tells us the match should
have been " 98" in the latter case.  It sure looks like a bug, I'll look
into it when I have some more time.
-- 
Sincerely,                                                          
srb(_at_)cuci(_dot_)nl
           Stephen R. van den Berg (AKA BuGless).

"I have a *cunning* plan!"

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