PR64140: Allow %{Content-Type} in health check expressions
Submitted By: Renier Velazco <renier.velazco upr.edu>
Commited By: covener
Github: closes #97
Submitted by: covener
Reviewed by: covener, ylavic, jim
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@
1874908 13f79535-47bb-0310-9956-
ffa450edef68
-*- coding: utf-8 -*-
Changes with Apache 2.4.42
+ *) mod_proxy_hcheck: Allow healthcheck expressions to use %{Content-Type}.
+ PR64140. [Renier Velazco <renier.velazco upr.edu>]
+
*) mod_authz_groupfile: Drop AH01666 from loglevel "error" to "info".
PR64172.
2.4.x patch: svn merge -c 1874323 ^/httpd/httpd/trunk .
+1: ylavic, gsmith, rpluem
- *) mod_proxy_hcheck: Allow %{Content-Type} to work in expressions
- trunk patch: http://svn.apache.org/r1874616
- 2.4.x patch: svn merge -c 1874616 ^/httpd/httpd/trunk .
- +1: covener, ylavic, jim
-
*) mod_http2: Fixes issue where mod_unique_id would generate non-unique request
identifier under load, see <https://github.com/icing/mod_h2/issues/195>.
trunk patch: http://svn.apache.org/r1874689
{
char buffer[HUGE_STRING_LEN];
int len;
+ const char *ct;
len = ap_getline(buffer, sizeof(buffer), r, 1);
if (len <= 0) {
} else {
return !OK;
}
+
/* OK, 1st line is OK... scarf in the headers */
while ((len = ap_getline(buffer, sizeof(buffer), r, 1)) > 0) {
char *value, *end;
*end = '\0';
apr_table_add(r->headers_out, buffer, value);
}
+
+ /* Set the Content-Type for the request if set */
+ if ((ct = apr_table_get(r->headers_out, "Content-Type")) != NULL)
+ ap_set_content_type(r, ct);
+
return OK;
}