curl-library
Why alter curl_multi_timeout() return value?
Date: Sun, 1 May 2011 16:59:52 -0700
The fopen.c example code contains:
curl_multi_timeout(multi_handle, &curl_timeo);
if(curl_timeo >= 0) {
timeout.tv_sec = curl_timeo / 1000;
if(timeout.tv_sec > 1)
timeout.tv_sec = 1;
else
timeout.tv_usec = (curl_timeo % 1000) * 1000;
}
Why is tv_sec clipped to 1 second? Why isn't the value returned by curl_multi_timeout() used as-is (after dividing by 1000)?
Assuming there's a good reason for the above, then is there a case when you would NOT clip the value to 1 second? What case is that?
- Paul
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-05-02