curl-library
Re: A Question On Curl
Date: Sun, 27 Jul 2014 23:17:39 -0700
Dan:
Thank You, Thank You, Thank You!
This fixed a number of issues.
Thomas Dineen
On 7/26/2014 1:41 PM, Dan Fandrich wrote:
> On Sat, Jul 26, 2014 at 12:36:23PM -0700, Thomas Dineen wrote:
>> The code shown below works about 98% of the time!
>>
>> About 2% of the time it will hang in url_fgets() maybe for 10
>> minutes or
>> more and sometimes longer.
>>
>> if the read fails that is ok, I just need it to return in an
>> orderly predictable way.
>>
>> Any ideas why or how to debug?
>>
>> I thought the CURLOPT_TIMEOUT would prevent this?
> [...]
>> handle = url_fopen ( URL_String, "r" );
> [...]
>> curl_easy_setopt( handle, CURLOPT_TIMEOUT, (long) 10 );
> You're mixing APIs here. url_fopen returns a URL_FILE* while
> curl_easy_setopt takes a CURL*. fopen.c is really just a demo program
> and isn't part of the libcurl API. You're free to modify it to add a
> timeout using the CURL* handle directly, but it's not designed to be a
> full-featured replacement for the curl easy API.
>
>>>> Dan
> -------------------------------------------------------------------
> List admin: http://cool.haxx.se/list/listinfo/curl-library
> Etiquette: http://curl.haxx.se/mail/etiquette.html
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2014-07-28