On Thu, Dec 11, 2003 at 10:38:06AM -0800, Stas Bekman wrote: > What's confusing is that it seems that most consumers (not filters) (e.g. in > protocol.c) that call ap_pass_brigade are completely ignoring its response > code.
It seems to me that many output filters are also ignoring ap_pass_brigade return code. Also, the few sample filters I've seen do that all the time. Lately I have been searching for a memory leak in my output filter and was wondering if it is safe to "return ap_pass_brigade(f->next, bb)" if my filter is holding on to some buckets in a private brigade which is hanging in f->ctx. Should a filter always check ap_pass_brigade return code and when it sees an error, cleanup its own mess before returning? Or does it matter? If the brigade was created with "apr_brigade_create(f->r->pool, f->c->bucket_alloc)", does it mean the brigade is cleaned up when the request pool is destroyed? And all the buckets in the brigade are returned to the allocator? -- Sami Tikka tel: +358 9 2520 5115 Senior Software Engineer fax: +358 9 2520 5013 F-Secure Corporation http://www.F-Secure.com/ F-Secure: Securing the Mobile, Distributed Enterprise
