You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by yl...@apache.org on 2015/12/30 01:16:51 UTC
svn commit: r1722251 - in /httpd/httpd/trunk/server: config.c core.c
Author: ylavic
Date: Wed Dec 30 00:16:50 2015
New Revision: 1722251
URL: http://svn.apache.org/viewvc?rev=1722251&view=rev
Log:
Follow up to r1715876: core directives are ASCII.
Modified:
httpd/httpd/trunk/server/config.c
httpd/httpd/trunk/server/core.c
Modified: httpd/httpd/trunk/server/config.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/config.c?rev=1722251&r1=1722250&r2=1722251&view=diff
==============================================================================
--- httpd/httpd/trunk/server/config.c (original)
+++ httpd/httpd/trunk/server/config.c Wed Dec 30 00:16:50 2015
@@ -1042,7 +1042,7 @@ AP_CORE_DECLARE(const command_rec *) ap_
const command_rec *cmds)
{
while (cmds->name) {
- if (!strcasecmp(name, cmds->name))
+ if (!ap_casecmpstr(name, cmds->name))
return cmds;
++cmds;
@@ -1197,8 +1197,8 @@ static const char *ap_build_config_sub(a
*bracket = '\0';
- if (strcasecmp(cmd_name + 2,
- (*curr_parent)->directive + 1) != 0) {
+ if (ap_casecmpstr(cmd_name + 2,
+ (*curr_parent)->directive + 1) != 0) {
parms->err_directive = newdir;
return apr_pstrcat(p, "Expected </",
(*curr_parent)->directive + 1, "> but saw ",
@@ -1244,7 +1244,7 @@ AP_DECLARE(const char *) ap_build_cont_c
while ((rc = ap_varbuf_cfg_getline(&vb, parms->config_file, max_len))
== APR_SUCCESS) {
if (!memcmp(vb.buf, "</", 2)
- && (strcasecmp(vb.buf + 2, bracket) == 0)
+ && (ap_casecmpstr(vb.buf + 2, bracket) == 0)
&& (*curr_parent == NULL)) {
break;
}
@@ -1621,7 +1621,7 @@ AP_DECLARE(const char *) ap_soak_end_con
if (cmd_name[1] == '/') {
cmd_name[strlen(cmd_name) - 1] = '\0';
- if (strcasecmp(cmd_name + 2, directive + 1) != 0) {
+ if (ap_casecmpstr(cmd_name + 2, directive + 1) != 0) {
return apr_pstrcat(cmd->pool, "Expected </",
directive + 1, "> but saw ",
cmd_name, ">", NULL);
@@ -2614,7 +2614,7 @@ static int count_directives_sub(const ch
while (current != NULL) {
if (current->first_child != NULL)
count += count_directives_sub(directive, current->first_child);
- if (strcasecmp(current->directive, directive) == 0)
+ if (ap_casecmpstr(current->directive, directive) == 0)
count++;
current = current->next;
}
Modified: httpd/httpd/trunk/server/core.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/core.c?rev=1722251&r1=1722250&r2=1722251&view=diff
==============================================================================
--- httpd/httpd/trunk/server/core.c (original)
+++ httpd/httpd/trunk/server/core.c Wed Dec 30 00:16:50 2015
@@ -1160,7 +1160,7 @@ static const ap_directive_t * find_paren
dirp = dirp->parent;
/* ### it would be nice to have atom-ized directives */
- if (strcasecmp(dirp->directive, what) == 0)
+ if (ap_casecmpstr(dirp->directive, what) == 0)
return dirp;
}
@@ -1360,7 +1360,7 @@ static void init_config_defines(apr_pool
static const char *set_define(cmd_parms *cmd, void *dummy,
const char *name, const char *value)
{
- if (cmd->parent && strcasecmp(cmd->parent->directive, "<VirtualHost")) {
+ if (cmd->parent && ap_casecmpstr(cmd->parent->directive, "<VirtualHost")) {
return apr_pstrcat(cmd->pool, cmd->cmd->name, " is not valid in ",
cmd->parent->directive, " context", NULL);
}
@@ -1391,7 +1391,7 @@ static const char *unset_define(cmd_parm
{
int i;
char **defines;
- if (cmd->parent && strcasecmp(cmd->parent->directive, "<VirtualHost")) {
+ if (cmd->parent && ap_casecmpstr(cmd->parent->directive, "<VirtualHost")) {
return apr_pstrcat(cmd->pool, cmd->cmd->name, " is not valid in ",
cmd->parent->directive, " context", NULL);
}