cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: url.c: setting password

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 8 Mar 2002 10:44:34 +0100 (MET)

On Thu, 7 Mar 2002, Jean-Philippe Barrette-LaPierre wrote:

> if I supply a NULL password callback (by CURLOPT_PASSWDFUNCTION and
> CURLOPT_PASSWDDATA) it doesn't return an error (I suppose if for ressetting
> the default callback).

Right, it simply stores the NULL...

> but if a supply an empty password, and then performing the curl, it tell me
> CURLE_BAD_PASSWORD_ENTERED.

Yeah, as it finds no function to invoke!

> Why don't you set a human readable error message for the
> CURLE_BAD_PASSWORD_ENTERED (line 1463 in lib/url.c in version 7.9.5) ?

That's a mistake.

> And why are you permitting to set an empty callback, if it's not to
> resseting the default?

We shouldn't, that's another mistake. Setting NULL should probably set back
the pointer to 'my_getpass'.

Would you be able to provide a patch for these?

-- 
    Daniel Stenberg -- curl groks URLs -- http://curl.haxx.se/
Received on 2002-03-08