curl-library
Mixing curl_easy_pause and curl_multi_socket_action
Date: Tue, 29 Mar 2016 18:57:16 +0200
I'm using curl_multi_socket_action(). Within the CURLOPT_HEADERFUNCTION I'm pausing the easy handle -- I need to asynchronously ask client code if the transfer should complete.
But after the curl_multi_socket_action() I'm getting a callback to my CURLMOPT_SOCKETFUNCTION and when I call curl_multi_socket_action() it tells me that the easy handle completed with CURLE_RECV_ERROR.
I tried pausing the easy handle with either
curl_easy_pause(handle, CURLPAUSE_ALL);
or by returning
CURL_WRITEFUNC_PAUSE
but it results in the same.
How should I go about pausing an easy transfer?
Should I simply remove it from the multi handle and re-add it once I'm ready to resume?
This is using plain HTTP and libcurl 7.43.0.
/Daniel
-------------------------------------------------------------------
List admin: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2016-03-29