cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Bad URL

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 6 Dec 2006 00:09:19 +0100 (CET)

On Tue, 5 Dec 2006, Manju Dash wrote:

> When I use curl_easy_setopt as following rv= curl_easy_setopt(curl_handle,
> CURLOPT_URL, "hello <http://google.com/> "); I still get the rv == 0 instead
> of any error code.
>
> I thought curl is handling if any bad URL is passed, but I don't know why I
> am getting CURLcode as 0.

Because that function only stores the pointer to what URL to use. You'll get
the error returned later when you call curl_easy_perform() (or whatever
function you use).

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2006-12-06