From: Ruediger Pluem Date: Mon, 7 Jan 2008 09:29:00 +0000 (+0000) Subject: * Optimize assignments by using apr_pcalloc instead of apr_palloc. X-Git-Tag: 2.3.0~1049 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8f1d7c06feda5a359b22850d07da1b3a94aced74;p=apache * Optimize assignments by using apr_pcalloc instead of apr_palloc. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@609541 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/http/http_filters.c b/modules/http/http_filters.c index 15448ed2b0..d1780264c1 100644 --- a/modules/http/http_filters.c +++ b/modules/http/http_filters.c @@ -191,13 +191,9 @@ apr_status_t ap_http_filter(ap_filter_t *f, apr_bucket_brigade *b, if (!ctx) { const char *tenc, *lenp; - f->ctx = ctx = apr_palloc(f->r->pool, sizeof(*ctx)); + f->ctx = ctx = apr_pcalloc(f->r->pool, sizeof(*ctx)); ctx->state = BODY_NONE; - ctx->remaining = 0; - ctx->limit_used = 0; - ctx->eos_sent = 0; ctx->pos = ctx->chunk_ln; - ctx->linesize = 0; /* LimitRequestBody does not apply to proxied responses. * Consider implementing this check in its own filter.