httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William A. Rowe, Jr." <>
Subject Re: htpasswd utility error (retar 2.0.21?)
Date Fri, 20 Jul 2001 19:30:34 GMT
I believe this is a showstopper for 2.0.21, unless we can agree to push the
support/htpasswd to revision 1.38 and reroll the tarball.

I'm sorry, I believed I had applied both the support/ and srclib/apr/file_io/win32
patches.  Turns out I only fixed APR, but the reason why it was still broken follows...

From: "Mladen Turk" <>
To: <>
Sent: Thursday, June 07, 2001 2:42 PM
Subject: htpasswd utility error

> Hi,
> Did someone ever tried to test the htpasswd.exe on Windows? (compiled
> with VC6 sp4)
> It doesn't work since version 2.0.b16.
> It can create the file and add the password, but if you try to add the
> password to the existing file then it reports:
> htpasswd: cannot modify file htpasswd; use '-c' to create it.
> Well, the file exists so I found out that the function apr_stat returns
> the false value for existing file.
> Changing the line 358 in htaccess.c from:
>     check = apr_stat(&sbuf, fname, APR_FINFO_NORM, NULL);
> to:
>     check = apr_stat(&sbuf, fname, APR_FINFO_MIN, NULL);
> then the htpasswd.exe works normal.

This was a twofold issue.  One, we really only wanted to know the filetype.
We really didn't want to accept a directory.  

Worse yet, NULL as an apr_pool_t* was completely bogus!!!

If we can push the htpasswd.c tag forward, then we can reroll, this is fixed
in revision 1.38, and otherwise win32 builds fine.


View raw message