From: Nick Kew Date: Mon, 25 Dec 2006 17:40:10 +0000 (+0000) Subject: PR#36609 - permit % as the last character of a Header value X-Git-Tag: 2.3.0~1953 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c9c0bbb448a500bdc5e15b79d80b18a24c3fb121;p=thirdparty%2Fapache%2Fhttpd.git PR#36609 - permit % as the last character of a Header value git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@490156 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/metadata/mod_headers.c b/modules/metadata/mod_headers.c index 34174a1809c..c7b2fc5d348 100644 --- a/modules/metadata/mod_headers.c +++ b/modules/metadata/mod_headers.c @@ -305,8 +305,8 @@ static char *parse_format_tag(apr_pool_t *p, format_tag *tag, const char **sa) } s++; /* skip the % */ - /* Pass through %% as % */ - if (*s == '%') { + /* Pass through %% or % at end of string as % */ + if ((*s == '%') || (*s == '\0')) { tag->func = constant_item; tag->arg = "%"; *sa = ++s;