Re: [exim] spam_score_int - what to do with negative values?

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Wolfgang Breyha
Dátum:  
Címzett: exim-users
Tárgy: Re: [exim] spam_score_int - what to do with negative values?
On 26/01/2023 14:43, Evgeniy Berdnikov via Exim-users wrote:
> The ">" comparison operator accepts integers, argument "-12.6" should raise
> an error. Negative values are valid. You can strip out dot with ${sg{..}},
> for example. Maybe there are some more elegant solutions...


But $spam_score_int is signed as well. And the condition used by the OP
should work just fine IMVHO.

At least my local exim 4.96 does report:
# exim -be '${if >{-200}{120}{1}{0}}'
0
# exim -be '${if >{200}{120}{1}{0}}'
1

Greetings, Wolfgang
--
Wolfgang Breyha <wbreyha@???> | https://www.blafasel.at/
Vienna University Computer Center | Austria