cURL / Mailing Lists / curl-library / Single Mail

curl-library

curl_multi_socket_action and speed limits

From: Dimitar Dimitrov <silent.cutthroat_at_gmail.com>
Date: Sat, 5 Sep 2009 03:03:45 +0300

Hello,

Maybe this is known, but I didn't find any reference to it. I've been
trying to go the socket_action way (curl-7.19.6) and run into the
following problem:

Reaching the speed limit, curl_multi_socket_action calls the socket
callback, removing the sole socket for the easy handle, so even
calling it again with CURL_CSELECT_IN doesn't do anything. I've came
up with two solutions:

  - use curl_multi_socket_perform, which is more of a workaround
  - change multi_getsock [lib/multi.c:779] to return the non-empty
bitmask in case of CURLM_STATE_TOOFAST, which if I understood the
source correctly, will cause curl_multi_fdset to feed too many
descriptors for selecting (I don't select)

Any suggestions?
Received on 2009-09-05