apr_brigade_flush flush,
void *ctx,
const char *str, apr_size_t nbyte)
{
apr_bucket *e = APR_BRIGADE_LAST(b);
apr_size_t remaining = APR_BUCKET_BUFF_SIZE;
char *buf = NULL;
if (!APR_BRIGADE_EMPTY(b) && APR_BUCKET_IS_HEAP(e)) {
apr_bucket_heap *h = e->data; remaining = h->alloc_len - e->length;
buf = h->base + e->start + e->length;
}Shouldn't that be "remaining = h->alloc_len - (e->length + e->start)"?
--Brian
