]> granicus.if.org Git - apache/commitdiff
Fixed an error in ap_ssi_get_tag_and_value(). It was not placing the
authorCliff Woolley <jwoolley@apache.org>
Tue, 7 Aug 2001 08:02:42 +0000 (08:02 +0000)
committerCliff Woolley <jwoolley@apache.org>
Tue, 7 Aug 2001 08:02:42 +0000 (08:02 +0000)
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

CHANGES
modules/filters/mod_include.c

diff --git a/CHANGES b/CHANGES
index 65bf0bc74de555d94c6f1f8dad5c06627f0f837d..36cb74f15d88a582e00423f9e30c4a61ed2e97e2 100644 (file)
--- 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 <hr> elements, 
      and HTMLTable to create rudimentary HTML table listings (implies 
index f3251b36197ee7587ca6cfa46360258559267635..a20daea4ee194e4c68d4aac5f574cbcfe9b96df0 100644 (file)
@@ -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);
     }