cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re[2]: could a call to curl_simple_request() block forever?

From: Dan Searle <dan_at_adelix.com>
Date: Fri, 31 Mar 2006 09:26:13 +0100

Hi,

Thursday, March 30, 2006, 6:56:51 PM, you wrote:

> On Thu, Mar 30, 2006 at 04:09:09PM +0100, Dan Searle wrote:
>> I have implemented a program which uses CURL to make HTTPS (SSL) POST
>> requests. The program is a non interactive daemon process, so it needs
>> to be 100%, my question is...
>>
>> Can a call to curl_simple_request() potentially block forever, i.e.
>> perhaps when a write() or read() call blocks and there's a problem
>> with the underlying socket.

> Presumably you mean curl_easy_perform().

Yes, sorry, writing from memory, and I'm quite dyslexic, hehehe.

>> If so I could implement an alarm call to force the forked process
>> which is handling the request to die (by calling _exit() from within
>> the SIGALARM signal handler. I don't want to have to do this if it's
>> not required, i.e. curl_simple_request() has a timeout feature already
>> implemented.

> Did you do 'man curl_easy_setopt' and search for 'timeout'?

I guess I should have looked a bit harder, thanks.

>>>> Dan

--
Dan Searle
Adelix Ltd
dan.searle_at_adelix.com web: www.adelix.com
tel: 0845 230 9590 / fax: 0845 230 9591 / support: 0845 230 9592
snail: The Old Post Office, Bristol Rd, Hambrook, Bristol BS16 1RY. UK.
Any views expressed in this email communication are those
of the individual sender, except where the sender specifically states
them to be the views of a member of Adelix Ltd.  Adelix Ltd. does not
represent, warrant or guarantee that the integrity of this communication
has been maintained nor that the communication is free of errors or
interference.
Received on 2006-03-31