Daniel, I thought CURLOPT_TIMEOUT(_MS) is only for setting transfer timeout, excluding connection part. I looked into libcurl code and found that libcurl uses the most restrictive one.
So in my case, the following settings should do the job I want. CURLOPT_TIMEOUT_MS=400 CURLOPT_CONNECTTIMEOUT_MS=0 Thanks for the pointer! On Sun, Aug 16, 2009 at 9:19 PM, Daniel Stenberg<[email protected]> wrote: > On Sun, 16 Aug 2009, Akira Kitada wrote: > >> libcurl provides two way of configuring how many time it can be allowed to >> take in its operation. >> >> * CURLOPT_TIMEOUT(_MS) >> * CURLOPT_CONNECTTIMEOUT(_MS) >> >> These options are very handy but in most cases, it doesn't matter in what >> operation libcurl took 400ms, rather I'd like to limit libcurl to take for >> connection+transfer. > > That's exactly what CURLOPT_TIMEOUT is for! > > -- > > / daniel.haxx.se >
