curl / Mailing Lists / curl-library / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: libcurl read-like interface

From: XSLT2.0 via curl-library <curl-library_at_cool.haxx.se>
Date: Sun, 27 Dec 2020 10:48:24 +0100

> We discourage users from using curl_easy_recv()

> for doing any protocol that libcurl implements natively. 

Ok, found it!

The solution was obvious, sorry for all the blurps: curl_easy_pause()

Inside the multi_perform/callbacks caller's loop, it allows better
control over the "transfer loop" from the caller's side.

I'll just have to be careful about "multi-threading unpause" (mutex-like
I assume!).


Shouldn't the PoC fcurl_read() use curl_easy_pause() instead of
buffering all in memory?


It is still scary to read in libcurl's documentation that when pausing
http/2 libcurl might buffer up to 32MB of data for each transfer!

Is there a "SETOPT" to control that?


Cheers

Alain

-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.se/mail/etiquette.html
Received on 2020-12-27