httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Bloom <...@covalent.net>
Subject Re: [PATCH] Rework httpd buckets/filtering
Date Sun, 23 Sep 2001 22:21:38 GMT
On Sunday 23 September 2001 03:12 pm, Justin Erenkrantz wrote:
> On Sun, Sep 23, 2001 at 03:04:54PM -0700, Ryan Bloom wrote:
> > That would be true if this function were to go into httpd, but it isn't. 
> > It is going into APR-util, and there is nothing saying that you will have
> > a brigade of a defined size.
>
> The doc for my proposed function (ap_brigade_to_buffer) says so.  =-)
> Otherwise, this function is useless - you have to have a defined
> size in order to copy it to a flat buffer.
>
> I used apr_brigade_partition to ensure that I had a defined length.
> If the partition failed, then it would have refused to copy.

Okay.  I still think it is bogus to have a function that takes an arbitrary brigade,
and tries to flatten it into a string, and does so by always calling 
APR_READ_BLOCK.  Actually, I think the whole function is bogus when I
really think about it.  We have already copied the data once, when we read
it from the socket.  We should really fix the ap_get_client_block API to either
return a bucket brigade, or it should return a pointer to a string.

What we are doing now, is forcing our clean bucket API into an API designed
around the BUFF logic.

Ryan

______________________________________________________________
Ryan Bloom				rbb@apache.org
Covalent Technologies			rbb@covalent.net
--------------------------------------------------------------

Mime
View raw message