On Tue, 12 Mar 2019, Badari Prasad wrote:
In continuation with this callback issue I am facing [and as per
https://curl.haxx.se/mail/lib-2011-09/0232.html] , if server sends
Transfer-Encoding: chunked, server will send the size of the chunked data
and the actual data to the client, libcurl consumes this size of chunked
data and invokes write callback function when data arrives at the client.
I was just wondering if libcurl can also pass this size of each chunk and
then invokes write function callback, this way my application will know size
of the chunk and can handle the multiple function call backs. Is this some
how possible with libcurl ?
curl already tells you the size of the data it delivers in every callback
invoke! There's no existing API for curl to inform the application about
chunked-encoded chunk sizes because that's something that curl abstracts away.
You can, if you really want to, ask curl to not decode the transfer encoding
and then you'll get to do the "dechunking" yourself. I wouldn't recommend it
though and I can't see how that would help you...
--
/ daniel.haxx.se
-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html