cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: check internet connection with curl

From: Dan Fandrich <dan_at_coneharvesters.com>
Date: Thu, 24 Apr 2008 23:37:16 -0700

On Fri, Apr 25, 2008 at 08:18:46AM +0200, Meir Yanovich wrote:
> ok i notice that simple doing:
> curl = curl_easy_init();
> it gives me cull == false when there is no internet connection
> can i base my check in that ?

If curl_easy_init() returns NULL, then, for whatever reason, you cannot use
libcurl. But there is no guarantee that when it returns != NULL that your
Internet connection is up.

>>> Dan

-- 
http://www.MoveAnnouncer.com              The web change of address service
          Let webmasters know that your web site has moved
Received on 2008-04-25