On 2010-05-05 at 10:52 -0700, Todd Lyons wrote:
> On Wed, May 5, 2010 at 8:44 AM, Ron White <exim.ml@???> wrote:
> >
> > each subcondition inside an "and{...}" condition must be in its own {}
> >
>
> > and {>={$spam_score_int}{$acl_m_spamscore}} {eq {$acl_m_spamscan}{2}}
> > ...
> > condition = ${if and {>={$spam_score_int}{$acl_m_spamscore}} {eq
> > {$acl_m_spamscan}{2}}}
> >
> > But that gives me:
> > temporarily rejected after DATA: failed to expand ACL string "${if and
> > {>={$spam_score_int}{$acl_m_spamscore}} {eq {$acl_m_spamscan}{2}}}":
> > each subcondition inside an "and{...}" condition must be in its own {}
Yes, you're missing the {} around all-the-branches.
> (Untested) Try adding another layer of braces around the conditions
> being passed to the and{} :
>
> ${if and {{>={$spam_score_int}{$acl_m_spamscore}} }
> {{eq{$acl_m_spamscan}{2} }} }
>
> Expanding it logically:
> ${if
> and{
> { >={$spam_score_int}{$acl_m_spamscore} }
> }
> {
> { eq{$acl_m_spamscan}{2} }
> }
> }
No, you've added extra braces around each point in turn.
${if CONDITION}
CONDITION: and{}
and{} takes sub-conditions, each of which is wrapped {inside-braces}
So Ron wants:
${if and{ {>={$spam_score_int}{$acl_m_spamscore}} \
{=={$acl_m_spamscan}{2}} } }
-Phil