From: Geoffrey Young Date: Fri, 30 Jan 2004 19:43:38 +0000 (+0000) Subject: Keep focus of ITERATE and ITERATE2 on the current module when X-Git-Tag: pre_ajp_proxy~749 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a193efa1b790dcb460d7977499d7c870c8a6b284;p=apache Keep focus of ITERATE and ITERATE2 on the current module when the module chooses to return DECLINE_CMD for the directive. PR: 22299 git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102469 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/CHANGES b/CHANGES index d7ee5f2ded..b8a622e6dd 100644 --- a/CHANGES +++ b/CHANGES @@ -2,9 +2,13 @@ Changes with Apache 2.1.0-dev [Remove entries to the current 2.0 section below, when backported] + *) Keep focus of ITERATE and ITERATE2 on the current module when + the module chooses to return DECLINE_CMD for the directive. + PR 22299. [Geoffrey Young ] + *) Allow mod_auth_digest to work with sub-requests with different methods than the original request. PR 25040. - [Josh Dady ] + [Josh Dady ] *) Fixed file extensions for real media files and removed rpm extension from mime.types. PR 26079. [Allan Sandfeld ] diff --git a/server/config.c b/server/config.c index 3fe65ad5ce..92e4db9bdc 100644 --- a/server/config.c +++ b/server/config.c @@ -697,7 +697,7 @@ static const char *invoke_cmd(const command_rec *cmd, cmd_parms *parms, void *mconfig, const char *args) { char *w, *w2, *w3; - const char *errmsg; + const char *errmsg = NULL; if ((parms->override & cmd->req_override) == 0) return apr_pstrcat(parms->pool, cmd->name, " not allowed here", NULL); @@ -797,11 +797,14 @@ static const char *invoke_cmd(const command_rec *cmd, cmd_parms *parms, case ITERATE: while (*(w = ap_getword_conf(parms->pool, &args)) != '\0') { - if ((errmsg = cmd->AP_TAKE1(parms, mconfig, w))) + + errmsg = cmd->AP_TAKE1(parms, mconfig, w); + + if (errmsg && strcmp(errmsg, DECLINE_CMD) != 0) return errmsg; } - return NULL; + return errmsg; case ITERATE2: w = ap_getword_conf(parms->pool, &args); @@ -812,11 +815,14 @@ static const char *invoke_cmd(const command_rec *cmd, cmd_parms *parms, cmd->errmsg ? ", " : NULL, cmd->errmsg, NULL); while (*(w2 = ap_getword_conf(parms->pool, &args)) != '\0') { - if ((errmsg = cmd->AP_TAKE2(parms, mconfig, w, w2))) + + errmsg = cmd->AP_TAKE2(parms, mconfig, w, w2); + + if (errmsg && strcmp(errmsg, DECLINE_CMD) != 0) return errmsg; } - return NULL; + return errmsg; case FLAG: w = ap_getword_conf(parms->pool, &args);