curl-library
Re: timeout
Date: Thu, 25 Jan 2001 09:51:03 +0100 (MET)
On Thu, 25 Jan 2001, Johan Nilsson wrote:
> > Feel free to add a timeout that does what you thought it did. I'm sure more
> > than you would like such a one. I'd appriciate a patch!
>
> Maybe I'll see what I can do in the future. Right now I don't have a lot
> of time :-)
Who has? ;-)
> > Without the timeout specificly set, it doesn't use any timers at all apart
> > from those the OS itself will use on system/network calls.
>
> What error code is signalled by libcurl if those OS timeouts occur? Is it
> CURLE_COULDNT_CONNECT, CURLE_COULDNT_RESOLVE_HOST or?
It depends on what function that returns failure. Both the above return codes
are valid return codes.
> Are the same codes sent even though some of the file has already been
> transfered, i.e. the transfer lost its "connection" to the server.
No. The code CURLE_COULDNT_CONNECT is for failed connect() and
CURLE_COULDNT_RESOLVE_HOST is for when the host name didn't resolve. When the
connection to the server is lost it may return CURLE_PARTIAL_FILE. It isn't
always possible to detect the difference between a "lost connection" and
end-of-file and then if so it may return CURLE_OK.
-- Daniel Stenberg -- curl project maintainer -- http://curl.haxx.se/ _______________________________________________ Curl-library mailing list Curl-library_at_lists.sourceforge.net http://lists.sourceforge.net/lists/listinfo/curl-libraryReceived on 2001-01-25