Skip to content

Commit 349b3fb

Browse files
author
Justin Erenkrantz
committed
mod_bucketeer needs to preserve error buckets if it sees them rather
than silently discarding them. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95412 13f79535-47bb-0310-9956-ffa450edef68
1 parent 483b149 commit 349b3fb

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

modules/test/mod_bucketeer.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@
6767
#include "util_filter.h"
6868
#include "apr_buckets.h"
6969
#include "http_request.h"
70+
#include "http_protocol.h"
7071

7172
static const char bucketeerFilterName[] = "BUCKETEER";
7273
module AP_MODULE_DECLARE_DATA bucketeer_module;
@@ -140,6 +141,13 @@ static apr_status_t bucketeer_out_filter(ap_filter_t *f,
140141
continue;
141142
}
142143

144+
if (AP_BUCKET_IS_ERROR(e)) {
145+
apr_bucket *err_copy;
146+
apr_bucket_copy(e, &err_copy);
147+
APR_BRIGADE_INSERT_TAIL(ctx->bb, err_copy);
148+
continue;
149+
}
150+
143151
/* read */
144152
apr_bucket_read(e, &data, &len, APR_BLOCK_READ);
145153

0 commit comments

Comments
 (0)