curl-library
Read and Write callbacks
Date: Fri, 29 Jan 2010 23:54:14 +0530
I am trying to see how a read or write callback would work for chunked
transfers.
The prototypes have the sig:-
Callback(void *ptr, size_t size, size_t nmemb, void *data)
and it seems size*nmemb should be total bytes transferred (transferrable?).
So if you are sending you have to keep track of the buffer position and feed
it (size*nmemb) bytes at a time?
And we can be sure that it will indeed send that many bytes, since curl
would know the MTU of the network interfaces involved during connection
negotiation and so on?
And vice versa for recieving?
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2010-01-29