Συντάκτης: Patrick Gosling Ημερομηνία: Προς: exim-users Υ/ο: jpmg Αντικείμενο: Re: [Exim] newlines in $message_body
In article <20020423.092620.1988@???> you write: >On Mon, 22 Apr 2002, Dean Brooks wrote:
>
>> We definitely have many scripts that depend upon the existing
>> behavior. Introducing line feeds would definitely make searching more
>> difficult as regexps would be required for almost every single search
>> at that point. Requiring regexp's can be unnecessarily complicated
>> for setting up a large numberof simple searches.
>
>OK. So the default clearly has to remain as it is.
Indeed - this still leaves the question open as to whether to have a
mechanism that toggles the behaviour (and defaults to the current
behaviour) or whether to have another variable ${message_body_nl} .
The former saves unnecessary memory allocations and data copies, while
the latter means that you can easily do both kinds of search in the
same filter.
>> An alternative question - why would someone want to keep the linefeeds
>> in $message_body? I'm sure there are legitimate needs but wasn't sure
>> what they would be...
>
>I suspect it is to do with analysing messages that have attachements.
Spot on! As another reply mentions, it's impossible to do this correctly
(ie without risk of false positives) if you can't distinguish between
space and new-line.