Re: [Exim] local_scan() addition: views sought

Páxina inicial
Borrar esta mensaxe
Responder a esta mensaxe
Autor: Tony Finch
Data:  
Para: ph10
CC: exim-users
Asunto: Re: [Exim] local_scan() addition: views sought
Philip Hazel <ph10@???> wrote:
>
>I don't really want to change the function's API by adding another
>string because this will make everybody's function stop working.
>
>The returned string may not contain any newlines for the success case.
>At the moment, newlines in the string are forced to become spaces. It
>occurs to me that I could use newline as a separator in this string:
>
> All characters before the first newline are saved in local_scan_data;
> All characters after the first newline (including any more newlines)
> become part of the 250 response.
>
>This is still an incompatible change, but a smaller one.
>
>Views?


I think that's ugly :-)

I suggest that you make an incompatible change to the API and rename the
local_scan function to (say) local_scan_2, and include a compatibility
shim local_scan_2 function that calls a local_scan function using the old
API. An alternative API numbering scheme might follow the version number
of Exim in which the API was changed, e.g. local_scan_411.

This does imply some build-up of cruft over time, but it's systematic
cruft rather than ad-hoc cruft.

Tony.
--
f.a.n.finch <dot@???> http://dotat.at/
NORTH UTSIRE SOUTH UTSIRE FORTIES: SOUTHEAST 5 TO 7, PERHAPS GALE 8 LATER.
OCCASIONAL RAIN. MODERATE OR GOOD.