diff options
-rw-r--r-- | it_url.class | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/it_url.class b/it_url.class index 1b82278..1e61578 100644 --- a/it_url.class +++ b/it_url.class @@ -398,9 +398,10 @@ function get_multi($p=null) $mrc = curl_multi_exec($mh, $active); } while ($mrc == CURLM_CALL_MULTI_PERFORM); + $timeout = 0.001; # Very short timeout to work around problem with first select call on cURL 7.25.0 while ($active && $mrc == CURLM_OK) { - if (curl_multi_select($mh) != -1) + if (curl_multi_select($mh, $timeout) != -1) { do { $mrc = curl_multi_exec($mh, $active); @@ -416,6 +417,7 @@ function get_multi($p=null) } } while ($mrc == CURLM_CALL_MULTI_PERFORM); } + $timeout = 0.1; # Longer delay to avoid busy loop but shorter than default of 1s in case we stil hit cURL 7.25.0 problem } $results = array(); |