summaryrefslogtreecommitdiffstats
path: root/modules/proxy/mod_proxy_http.c
diff options
context:
space:
mode:
authorRuediger Pluem <rpluem@apache.org>2016-01-26 12:59:07 +0100
committerRuediger Pluem <rpluem@apache.org>2016-01-26 12:59:07 +0100
commit19fd02fdeb4269b39f233f93c6c08efc18fba501 (patch)
treefcfea41594c2ad8142aa93ad81db6969063a8c83 /modules/proxy/mod_proxy_http.c
parentmod_filter: Fix AddOutputFilterByType with non-content-level filters. (diff)
downloadapache2-19fd02fdeb4269b39f233f93c6c08efc18fba501.tar.xz
apache2-19fd02fdeb4269b39f233f93c6c08efc18fba501.zip
* For creating new buckets always use the bucket allocator of the brigade in
which we want to put the bucket. Currently this does not change behaviour as r->connection->bucket_alloc and to->bucket_alloc are the same. It is a cleanup and preparation for abstracting this in a proxy API. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1726776 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '')
-rw-r--r--modules/proxy/mod_proxy_http.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/modules/proxy/mod_proxy_http.c b/modules/proxy/mod_proxy_http.c
index 9f3bdc710f..52b444e69b 100644
--- a/modules/proxy/mod_proxy_http.c
+++ b/modules/proxy/mod_proxy_http.c
@@ -692,6 +692,7 @@ static apr_status_t proxy_buckets_lifetime_transform(request_rec *r,
const char *data;
apr_size_t bytes;
apr_status_t rv = APR_SUCCESS;
+ apr_bucket_alloc_t *bucket_alloc = to->bucket_alloc;
apr_brigade_cleanup(to);
for (e = APR_BRIGADE_FIRST(from);
@@ -699,15 +700,15 @@ static apr_status_t proxy_buckets_lifetime_transform(request_rec *r,
e = APR_BUCKET_NEXT(e)) {
if (!APR_BUCKET_IS_METADATA(e)) {
apr_bucket_read(e, &data, &bytes, APR_BLOCK_READ);
- new = apr_bucket_transient_create(data, bytes, r->connection->bucket_alloc);
+ new = apr_bucket_transient_create(data, bytes, bucket_alloc);
APR_BRIGADE_INSERT_TAIL(to, new);
}
else if (APR_BUCKET_IS_FLUSH(e)) {
- new = apr_bucket_flush_create(r->connection->bucket_alloc);
+ new = apr_bucket_flush_create(bucket_alloc);
APR_BRIGADE_INSERT_TAIL(to, new);
}
else if (APR_BUCKET_IS_EOS(e)) {
- new = apr_bucket_eos_create(r->connection->bucket_alloc);
+ new = apr_bucket_eos_create(bucket_alloc);
APR_BRIGADE_INSERT_TAIL(to, new);
}
else {