From: Paul Querna Date: Tue, 24 May 2005 17:25:41 +0000 (+0000) Subject: Fix trailing backslashes in configuration directives. X-Git-Tag: 2.1.5~79 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=897691ca2db194ffed7f2af8e3a798fa5502763f;p=apache Fix trailing backslashes in configuration directives. PR: 34834 Submitted by: Timo Viipuri Reviewed by: Paul Querna git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@178209 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/CHANGES b/CHANGES index 3e11cfa511..4981527ded 100644 --- a/CHANGES +++ b/CHANGES @@ -2,6 +2,9 @@ Changes with Apache 2.1.5 [Remove entries to the current 2.0 section below, when backported] + *) ap_getword_conf: Fix backslashes at the end of configuration directives. + PR 34834. [Timo Viipuri ] + *) mod_dbd: New additions: mod_dbd.c, mod_dbd.h, mod_dbd.xml Provide module hooks for apr_dbd; optimise for httpd threaded and non-threaded arch [Nick Kew] diff --git a/server/util.c b/server/util.c index f506423b24..34d7ce51ae 100644 --- a/server/util.c +++ b/server/util.c @@ -732,10 +732,13 @@ AP_DECLARE(char *) ap_getword_conf(apr_pool_t *p, const char **line) if ((quote = *str) == '"' || quote == '\'') { strend = str + 1; while (*strend && *strend != quote) { - if (*strend == '\\' && strend[1] && strend[1] == quote) + if (*strend == '\\' && strend[1] && + (strend[1] == quote || strend[1] == '\\')) { strend += 2; - else + } + else { ++strend; + } } res = substring_conf(p, str + 1, strend - str - 1, quote);