cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: No Errorcode in commandline will be returned even http errors occ ured

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Mon, 30 Oct 2006 10:24:59 +0100 (CET)

On Mon, 30 Oct 2006, TP wrote:

>> This is a bug in libcurl (for the 401 response code), so you need to make a
>> work-around. I think you can use -w to get the HTTP response code and use
>> that to detect this problem.

> This option will only write this information to the stout, or not?

Yes it does.

> So my only possibility is to parse the output and decide with an external
> script if an error has occured or not.

Correct. Or upgrade to the just released 7.16.0 which at least fixes that
exact case. The 401/407 responses aren't always gonna be possible to trigger
with -f anyway. so the -w is the only really good way to catch this.

> Exists any other workaround, which makes not necessary to develop an
> external script?

I don't think so, but then I don't have all the answers.

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