On 22 May 2013, at 1:06 PM, Yann Ylavic <ylavic....@gmail.com> wrote:

> On 05/14/2013 08:58 PM, minf...@apache.org wrote:
> > Author: minfrin 
> > Date: Tue May 21 16:10:02 2013 
> > New Revision: 1484852 
> >
> > URL: http://svn.apache.org/r1484852 
> > Log: 
> > core: Remove apr_brigade_flatten(), buffering and duplicated code 
> > from the HTTP_IN filter, parse chunks in a single pass with zero copy. 
> > Reduce memory usage by 48 bytes per request. 
> >
> > Modified: 
> > httpd/httpd/trunk/CHANGES 
> > httpd/httpd/trunk/modules/http/http_filters.c 
> 
> Shouldn't the BODY_CHUNK_END state only accept [CR]LF ?
> Currently anything but a LF is ignored.

Yep, as is pointed out in this comment:

        /* handle a chunk part, or a chunk extension */
        /*
         * In theory, we are supposed to expect CRLF only, but our
         * test suite sends LF only. Tolerate a missing CR.
         */
        if (c == ';' || c == CR) {
            ctx->state = BODY_CHUNK_EXT;
        }

Our test suite uses LF instead of CRLF as a chunk terminator in many cases, and 
we don't know what code in the wild depends on this behaviour. This isn't 
something we're going to fix easily.

Regards,
Graham
--

Reply via email to