At 20:08 2002-10-28 +0100, Dallman Ross did say:
58 of my most recent 100 spam messages were ID'd by this recipe.
Well, dangit, share the details!
:0 # 021026 () score should equal three
* $ ! $= ?? ^^3^^
Why are you using the $ flag? in fact, is it even necessary to use $= when
checking a score variable - syntactically, shouldn't you just use:
* ! = ?? ^^3^^
unimportant to what's going on with the action. The score is
right. Procmail seems to be saying that 3 != 3. Hmm.
If you place the recipe into a sandbox and pass the same message at it,
does it act the same? If so, that's good because it's reproduceable. Now,
try ASSIGNING the score to a variable within the nesting before checking
it, and using that variable in the comparison instead. Any change?
You could assign it to a variable and use it in scoring: make it a negative
and add three.
SAVEDSCORE=$=
:0
* $ -$SAVEDSCORE^0
* 3^0
{
#spam action
}
This would trigger if it's LESS than 3 (i.e. isn't really the same as
tripping only when equal to 3).
(or, simply code your outer recipe to add three and use negative scoring on
each element, then you don't need a nesting at all, unless you're looking
to use the score value for something)
FTR, I was able to reproduce your problem with:
:0
* 3^0
{
}
:0
* $ ! $= ?? ^^3^^
{
LOG="we be here$NL"
}
Using a variable however:
:0
* 3^0
{
}
SAVEDSCORE=$=
:0
* ! SAVEDSCORE ?? ^^3^^
{
LOG="we be here$NL"
}
Results in:
procmail: Score: 3 3 ""
procmail: Assigning "SAVEDSCORE=3"
procmail: No match on ! "^^3^^"
and (forcing a non-3 score in the recipe):
procmail: Score: 2 2 ""
procmail: Assigning "SAVEDSCORE=2"
procmail: Match on ! "^^3^^"
Specifically note the syntax of the match line. Compare that to the
results of the stripped down test script using $=
procmail: Score: 3 3 ""
procmail: Match on ! "3 ?? ^^3^^"
and
procmail: Score: 2 2 ""
procmail: Match on ! "= ?? ^^3^^"
Note that the LHS variable is expanded there. I believe this indicates an
issue with handling expansion of the special variable $=. I'm surprised
that you have success at all with it.
---
Sean B. Straw / Professional Software Engineering
Procmail disclaimer: <http://www.professional.org/procmail/disclaimer.html>
Please DO NOT carbon me on list replies. I'll get my copy from the list.
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail