httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cove...@apache.org
Subject svn commit: r1791400 - in /httpd/httpd/trunk: CHANGES modules/filters/mod_substitute.c
Date Fri, 14 Apr 2017 19:38:34 GMT
Author: covener
Date: Fri Apr 14 19:38:34 2017
New Revision: 1791400

URL: http://svn.apache.org/viewvc?rev=1791400&view=rev
Log:
mod_substitute: use local/native LF for splitting

On platforms where the APR_ASCII_LF != '\n', like EBCDIC systems,
strmatch or pcre patterns from the source or config will be in
the native encoding, and this module will really only work on 
content in the native encoding.

(mod_substitute runs before mod_charset_lite for a similar reason)

I thought #if APR_CHARSET_EBCDIC or even #ifdef __MVS__ was overkill
here. 



Modified:
    httpd/httpd/trunk/CHANGES
    httpd/httpd/trunk/modules/filters/mod_substitute.c

Modified: httpd/httpd/trunk/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/CHANGES?rev=1791400&r1=1791399&r2=1791400&view=diff
==============================================================================
--- httpd/httpd/trunk/CHANGES [utf-8] (original)
+++ httpd/httpd/trunk/CHANGES [utf-8] Fri Apr 14 19:38:34 2017
@@ -1,6 +1,9 @@
                                                          -*- coding: utf-8 -*-
 Changes with Apache 2.5.0
 
+  *) mod_substitute: Fix spurious AH01328 (Line too long) errors on EBCDIC
+     systems.  [Eric Covener]
+
   *) mod_http2: client streams that lack the EOF flag get now forcefully
      closed with a RST_STREAM (NO_ERROR) when the request has been answered.
      [Stefan Eissing]     

Modified: httpd/httpd/trunk/modules/filters/mod_substitute.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/filters/mod_substitute.c?rev=1791400&r1=1791399&r2=1791400&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/filters/mod_substitute.c (original)
+++ httpd/httpd/trunk/modules/filters/mod_substitute.c Fri Apr 14 19:38:34 2017
@@ -453,7 +453,7 @@ static apr_status_t substitute_filter(ap
             else {
                 int num = 0;
                 while (bytes > 0) {
-                    nl = memchr(buff, APR_ASCII_LF, bytes);
+                    nl = memchr(buff, '\n', bytes);
                     if (nl) {
                         len = (apr_size_t) (nl - buff) + 1;
                         /* split *after* the newline */



Mime
View raw message