-*- coding: utf-8 -*-
Changes with Apache 2.5.0
+ *) "Iterate" directives: Report an error if no arguments are provided.
+ [Jeff Trawick]
+
*) htpasswd, htdbm: Optionally read passwords from stdin, as more
secure alternative to -b. PR 40243. [Adomas Paltanavicius <adomas
paltanavicius gmail com>, Stefan Fritsch]
return cmd->AP_TAKE3(parms, mconfig, w, w2, w3);
case ITERATE:
- while (*(w = ap_getword_conf(parms->pool, &args)) != '\0') {
+ w = ap_getword_conf(parms->pool, &args);
+
+ if (*w == '\0')
+ return apr_pstrcat(parms->pool, cmd->name,
+ " requires at least one argument",
+ cmd->errmsg ? ", " : NULL, cmd->errmsg, NULL);
+ while (*w != '\0') {
errmsg = cmd->AP_TAKE1(parms, mconfig, w);
if (errmsg && strcmp(errmsg, DECLINE_CMD) != 0)
return errmsg;
+
+ w = ap_getword_conf(parms->pool, &args);
}
return errmsg;