Re: [exim] dlfunc yield value protocol

Top Page

Reply to this message
Author: Jeremy Harris
To: exim-users
Subject: Re: [exim] dlfunc yield value protocol
On 28/01/2019 19:00, Ian Zimmerman via Exim-users wrote:
> On 2019-01-24 14:10, Ian Zimmerman wrote:
>> On 2019-01-24 20:44, Jeremy Harris wrote:
>>> string_sprintf()
>>> string_copy()
>>> string_copyn()
>> Exactly what I was hoping for! Thanks.
> A follow-up question. Can I do the analogue of realloc()?
> I am trying to construct a list (in the Exim sense) and return it from
> the dlfunc module. I don't know a priori how long the list will be or
> how many elements.

Not with the documented API.

The internal way to do it would be one of



... all of which deal in objects called "growable string".
You don't need to alloc or realloc at all.