cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Which timeout expired? CURLOPT_TIMEOUT or CURLOPT_CONNECTTIMEOUT?

From: Dirk Manske <dm_at_nonitor.de>
Date: Sun, 13 Feb 2011 21:58:24 +0100

> Is there a way to recognize which of CURLOPT_TIMEOUT and
> CURLOPT_CONNECTTIMEOUT timeouts has expired?
Have check the return code?

I think they should be

CURLE_OPERATION_TIMEDOUT => CURLOPT_TIMEOUT
CURLE_COULDNT_CONNECT => CURLOPT_CONNECTTIMEOUT

Otherwise use curl_easy_getinfo and check the time data.
Also the timeout errors have different error messages.
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-02-13