> -----Original Message----- > From: Stefan Fritsch [mailto:[email protected]] > Sent: Montag, 29. August 2011 18:00 > To: [email protected] > Subject: Re: svn commit: r1162881 - > /httpd/httpd/branches/2.2.x/modules/http/byterange_filter.c > > On Mon, 29 Aug 2011, [email protected] wrote: > > > Author: jim > > Date: Mon Aug 29 15:53:52 2011 > > New Revision: 1162881 > > > > URL: http://svn.apache.org/viewvc?rev=1162881&view=rev > > Log: > > Allow for actual counting... > > > > Modified: > > httpd/httpd/branches/2.2.x/modules/http/byterange_filter.c > > > > Modified: httpd/httpd/branches/2.2.x/modules/http/byterange_filter.c > > URL: > http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/module > s/http/byterange_filter.c?rev=1162881&r1=1162880&r2=1162881&view=diff > > > ============================================================== > ================ > > --- > httpd/httpd/branches/2.2.x/modules/http/byterange_filter.c (original) > > +++ > httpd/httpd/branches/2.2.x/modules/http/byterange_filter.c > Mon Aug 29 15:53:52 2011 > > @@ -137,6 +137,7 @@ static apr_status_t copy_brigade_range(a > > if (off_first != start64) { > > rv = apr_bucket_split(copy, > (apr_size_t)(start64 - off_first)); > > if (rv == APR_ENOTIMPL) { > > + int i; > > rv = apr_bucket_read(copy, &s, &len, > APR_BLOCK_READ); > > if (rv != APR_SUCCESS) { > > apr_brigade_cleanup(bbout); > > @@ -147,9 +148,10 @@ static apr_status_t copy_brigade_range(a > > * of shorter length. So read and > delete until we reached > > * the correct bucket for splitting. > > */ > > + i = 0; > > while (start64 - off_first > > (apr_uint64_t)copy->length) { > > apr_bucket *tmp; > > - int i = 0; > > + /* don't allow inf. spin */ > > if (i++ >= 99999) > > return APR_EINVAL; > > > > IMNSHO such changes need to be voted upon before commiting to > branches/2.2.x. When can this case happen? And why do it for > the start > bucket but not for the end bucket?
Agreed. Please let us bring this in shape in trunk and backport a voted solution later on to 2.2.x. Regards Rüdiger >
