Re: [PATCH] Interpreted Range memory leak (3.0 only)

From: Alex Rousskov <rousskov_at_measurement-factory.com>
Date: Tue, 13 Jul 2010 10:33:51 -0600

On 02/04/2010 03:01 PM, Amos Jeffries wrote:
> Alex Rousskov wrote:
>> Prevent memory leaks when interpreting Range requests.
>>
>> HttpRequest::range field could be set to a new HttpHdrRange object
>> twice: once in clientInterpretRequestHeaders() and once in
>> HttpRequest::hdrCacheInit() called from HttpRequest::parseHeader().
>>
>> HttpRequest::range field could be cleared without destroying
>> HttpHdrRange object in clientInterpretRequestHeaders().
>>
>> The range field is essentially a cached value of the parsed Range
>> header. Managing the cache outside its owner object is a bad idea.
>>
>
> +1.

Committed to trunk. The leak probably exists in both 3.1 and 3.0 despite
my misleading or wrong "3.0 only" tag in the subject.

Thank you,

Alex.
Received on Tue Jul 13 2010 - 16:34:53 MDT

This archive was generated by hypermail 2.2.0 : Tue Jul 13 2010 - 12:00:16 MDT