curl-library
Re: passing state in write callbacks
Date: Thu, 15 Sep 2011 14:18:55 -0700
On Thu, Sep 15, 2011 at 2:12 PM, Daniel Stenberg <daniel_at_haxx.se> wrote:
> On Thu, 15 Sep 2011, Alex Loukissas wrote:
>
>> My question is whether libcurl supports/will support a different kind
>> of signature for the callback function, one with an extra (void *)
>> argument, where we can pass in some state (and thus make it a truer
>> sort-of-speak callback).
>
> Why can't you just use the existing void * argument?
Correct me if I'm wrong, but doesn't this contain the data read by
curl to be written to the file? At least this is what's passed onto
fwrite( ).
>
> --
>
> / daniel.haxx.se
> -------------------------------------------------------------------
> List admin: http://cool.haxx.se/list/listinfo/curl-library
> Etiquette: http://curl.haxx.se/mail/etiquette.html
>
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-09-15