apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William A. Rowe, Jr." <wr...@rowe-clan.net>
Subject Re: [PATCH] apr_uri_unparse_components monthly reminder
Date Fri, 17 Aug 2001 18:21:31 GMT
Jon,

  can you take a look at the attached bug report, and assure that your patch
handles this case correctly before we apply it today?  I'd like to lick all
the bugs, and wanted to be sure that this report is dead as well (on 2.0.)

Bill

    

----- Original Message ----- 
From: "Jon Travis" <jtravis@covalent.net>
To: <dev@apr.apache.org>
Sent: Friday, August 17, 2001 12:55 PM
Subject: [PATCH] apr_uri_unparse_components monthly reminder


> This is a reminder, sent out once a month, about a previous APR 
> patch submission.   It includes the patch, description, and how to 
> use it to fix broken code.
> 
> Original patch post date:  Jul-18-2001
> 
> Description:
> 
> apr_uri_unparse_components can unparse components into an invalid
> URI.  If the components contain either a user or password, the 
> unparsed URI will always contain an '@' symbol.  This is incorrect,
> since the UNP_OMITPASSWORD and UNP_OMITUSER flags can affect 
> this functionality.  I.e. if the components contain either a user
> or password, and flags to omit both the user and password from the
> unparsed URI are given, the output should contain no '@' symbol.
> 
> The patch:
> 
> ? uri/patch.diff
> Index: uri/apr_uri.c
> ===================================================================
> RCS file: /home/cvspublic/apr-util/uri/apr_uri.c,v
> retrieving revision 1.6
> diff -u -u -r1.6 apr_uri.c
> --- uri/apr_uri.c 2001/06/13 22:56:23 1.6
> +++ uri/apr_uri.c 2001/07/23 17:21:39
> @@ -139,7 +139,9 @@
>   (uptr->password && !(flags & UNP_OMITPASSWORD))
>      ? ((flags & UNP_REVEALPASSWORD) ? uptr->password : "XXXXXXXX")
>      : "",
> - "@", NULL);
> + ((uptr->user && !(flags & UNP_OMITUSER)) ||
> + (uptr->password && !(flags & UNP_OMITPASSWORD))) ? "@" 
> + : "", NULL);
>  
>   /* Construct scheme://site string */
>   if (uptr->hostname) {
> 

Mime
View raw message