httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cove...@apache.org
Subject svn commit: r1682482 - in /httpd/httpd/trunk: CHANGES server/core.c
Date Fri, 29 May 2015 14:22:11 GMT
Author: covener
Date: Fri May 29 14:22:10 2015
New Revision: 1682482

URL: http://svn.apache.org/r1682482
Log:
PR 57968: Don't lowercase the argument to SetHandler if the handler is
proxy:unix.


Modified:
    httpd/httpd/trunk/CHANGES
    httpd/httpd/trunk/server/core.c

Modified: httpd/httpd/trunk/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/CHANGES?rev=1682482&r1=1682481&r2=1682482&view=diff
==============================================================================
--- httpd/httpd/trunk/CHANGES [utf-8] (original)
+++ httpd/httpd/trunk/CHANGES [utf-8] Fri May 29 14:22:10 2015
@@ -1,6 +1,9 @@
                                                          -*- coding: utf-8 -*-
 Changes with Apache 2.5.0
 
+  *) core: Don't lowercase the argument to SetHandler if it begins with
+     "proxy:unix". PR 57968. [Eric Covener]
+
   *) mod_ssl: add ALPN support by allowing other modules to register callbacks
      for negotiation of the application layer protocol.  PR 52210.
      [Matthew Steele <mdsteele google com>, Joe Orton, Jim Jagielski,

Modified: httpd/httpd/trunk/server/core.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/core.c?rev=1682482&r1=1682481&r2=1682482&view=diff
==============================================================================
--- httpd/httpd/trunk/server/core.c (original)
+++ httpd/httpd/trunk/server/core.c Fri May 29 14:22:10 2015
@@ -1926,6 +1926,24 @@ static const char *set_default_type(cmd_
     return NULL;
 }
 
+static const char *set_sethandler(cmd_parms *cmd,
+                                     void *d_,
+                                     const char *arg_)
+{
+    core_dir_config *dirconf = d_;
+
+    if (arg_ == ap_strstr_c(arg_, "proxy:unix")) { 
+        dirconf->handler = arg_;
+    }
+    else { 
+        char *arg = apr_pstrdup(cmd->pool,arg_);
+        ap_str_tolower(arg);
+        dirconf->handler = arg;
+    }
+
+    return NULL;
+}
+
 /*
  * Note what data should be used when forming file ETag values.
  * It would be nicer to do this as an ITERATE, but then we couldn't
@@ -4371,8 +4389,7 @@ AP_INIT_FLAG("CGIPassAuth", set_cgi_pass
 AP_INIT_TAKE1("ForceType", ap_set_string_slot_lower,
        (void *)APR_OFFSETOF(core_dir_config, mime_type), OR_FILEINFO,
      "a mime type that overrides other configured type"),
-AP_INIT_TAKE1("SetHandler", ap_set_string_slot_lower,
-       (void *)APR_OFFSETOF(core_dir_config, handler), OR_FILEINFO,
+AP_INIT_TAKE1("SetHandler", set_sethandler, NULL, OR_FILEINFO,
    "a handler name that overrides any other configured handler"),
 AP_INIT_TAKE1("SetOutputFilter", ap_set_string_slot,
        (void *)APR_OFFSETOF(core_dir_config, output_filters), OR_FILEINFO,



Mime
View raw message