From: Cliff Woolley Date: Tue, 7 Aug 2001 08:02:42 +0000 (+0000) Subject: Fixed an error in ap_ssi_get_tag_and_value(). It was not placing the X-Git-Tag: 2.0.23~34 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7e9903172e8c40df89cbced859c9abd2d8549072;p=apache Fixed an error in ap_ssi_get_tag_and_value(). It was not placing the null terminator in the right spot for the tag_val if the value contained backslashes. This caused #if, #elif, and #else expressions with backslashes to be incorrectly evaluated. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89980 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/CHANGES b/CHANGES index 65bf0bc74d..36cb74f15d 100644 --- a/CHANGES +++ b/CHANGES @@ -1,5 +1,9 @@ Changes with Apache 2.0.23-dev + *) Fixed an error in mod_include's directive parsing routines which + caused #if, #elif, and #else expressions containing backslashes + to be improperly evaluated. [Cliff Woolley] + *) Introduced new mod_autoindex IndexOptions flags; SuppressIcon to drop the icon column, SuppressRules to drop the
elements, and HTMLTable to create rudimentary HTML table listings (implies diff --git a/modules/filters/mod_include.c b/modules/filters/mod_include.c index f3251b3619..a20daea4ee 100644 --- a/modules/filters/mod_include.c +++ b/modules/filters/mod_include.c @@ -593,8 +593,8 @@ static void ap_ssi_get_tag_and_value(include_ctx_t *ctx, char **tag, } } - *c++ = '\0'; /* Overwrites delimiter (term or WS) with NULL. */ - ctx->curr_tag_pos = c; + *(c-shift_val) = '\0'; /* Overwrites delimiter (term or WS) with NULL. */ + ctx->curr_tag_pos = ++c; if (dodecode) { decodehtml(*tag_val); }