From: André Malo Date: Thu, 24 Apr 2003 16:08:21 +0000 (+0000) Subject: When using Redirect in directory context, append requested query X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0f8d9bedf6c0097dc0c61617e990e0a35877a1c4;p=thirdparty%2Fapache%2Fhttpd.git When using Redirect in directory context, append requested query string if there's no one supplied by configuration. PR: 10961 Reviewed by: Jeff Trawick, Jim Jagielski git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@99579 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/CHANGES b/src/CHANGES index e0831ae47e0..3c6816a972e 100644 --- a/src/CHANGES +++ b/src/CHANGES @@ -1,5 +1,9 @@ Changes with Apache 1.3.28 + *) When using Redirect in directory context, append requested query + string if there's no one supplied by configuration. PR 10961. + [André Malo] + *) Fix path handling of mod_rewrite, especially on non-unix systems. There was some confusion between local paths and URL paths. PR 12902. [André Malo] diff --git a/src/modules/standard/mod_alias.c b/src/modules/standard/mod_alias.c index 98b148dc7cf..78e7b17fb3e 100644 --- a/src/modules/standard/mod_alias.c +++ b/src/modules/standard/mod_alias.c @@ -411,6 +411,12 @@ static int fixup_redir(request_rec *r) r->uri, ret); } else { + /* append requested query only, if the config didn't + * supply its own. + */ + if (r->args && !strchr(ret, '?')) { + ret = ap_pstrcat(r->pool, ret, "?", r->args, NULL); + } ap_table_setn(r->headers_out, "Location", ret); } }