[exim-dev] [Bug 1533] headers_remove items size-limited

Top Page
Delete this message
Reply to this message
Author: Ralf G R Bergs
Date:  
To: exim-dev
Old-Topics: [exim-dev] [Bug 1533] New: headers_remove items size-limited
Subject: [exim-dev] [Bug 1533] headers_remove items size-limited
------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=1533




--- Comment #11 from Ralf G. R. Bergs <Ralf-Exim@???> 2015-03-24 16:58:50 ---
(In reply to comment #10)
> Aha. headers_remove expects a colon-sep list, so it takes the bare string
> you feed it and splits at colons. The part up to and including the 'A' is
> the first element of that list. Each element then has string-expansion applied
> -
> so the (now) badly-formed ${if } is evaluated.
>
> The documentation hints at this: "Each item is separately expanded".
>
> If the list is short, just double the colons.


I can confirm that your hint helps making the shortened example work, so thanks
for it.

BUT unfortunately I have two issues:

1) I don't understand your above comments. It's been many years ago when I was
fluent in "Eximish." Can you please be a bit more elaborate?
2) Your above advice doesn't help in the original code fragment, which is the
following:

-  headers_remove = ${if or {{<{$spam_score_int}{${lookup mysql{select
users.sa_tag * 10 from users,domains \
-                              where localpart = '${quote_mysql:$local_part}' \
-                              and domain = '${quote_mysql:$domain}' \
-                              and users.on_spamassassin = 1 \
-                              and
users.domain_id=domains.domain_id}{$value}}}} \
-                            { eq {0}{${lookup mysql{select
users.on_spamassassin from users,domains \
-                              where localpart = '${quote_mysql:$local_part}' \
-                              and domain = '${quote_mysql:$domain}' \
-                              and
users.domain_id=domains.domain_id}{$value}}}} \
-                          } {X-Spam-Score:X-Spam-Report:X-New-Subject} }


Thanks!


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email