[exim] Unexpected ${match} behaviour

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Mike Cardwell
Date:  
À: Exim Mailing List
Sujet: [exim] Unexpected ${match} behaviour
Hi,

Can someone explain this to me please:

root@clayman:~# exim -be '${if
match{1}{(1)}{${extract{$1}{}{true}}}{false}}'
true
root@clayman:~# exim -be '${if
match{1}{(2)}{${extract{$1}{}{true}}}{false}}'
Failed: first argument of "extract" must not be empty
root@clayman:~#

Why does it fail the second time? Surely it should have just printed out
the word "false" ? The match doesn't succeed so surely the second time
the ${extract} shouldn't even be attempted?

Is this by design?

Mike