From 20a7482f93c78c25624f38d7d49b9d7dc2e553f7 Mon Sep 17 00:00:00 2001 From: Ryan Bloom Date: Wed, 25 Oct 2000 10:47:51 +0000 Subject: [PATCH] Add a comment about a requirement with the eos_sent variable. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86742 13f79535-47bb-0310-9956-ffa450edef68 --- server/util_filter.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/server/util_filter.c b/server/util_filter.c index b63b22d9a3..937db41777 100644 --- a/server/util_filter.c +++ b/server/util_filter.c @@ -239,6 +239,14 @@ AP_DECLARE(apr_status_t) ap_pass_brigade(ap_filter_t *next, ap_bucket_brigade *b if (next) { ap_bucket *e; if ((e = AP_BRIGADE_LAST(bb)) && AP_BUCKET_IS_EOS(e) && next->r) { + /* This is only safe because HTTP_HEADER filter is always in + * the filter stack. This ensures that there is ALWAYS a + * request-based filter that we can attach this to. If the + * HTTP_FILTER is removed, and another filter is not put in its + * place, then handlers like mod_cgi, which attach their own + * EOS bucket to the brigade will be broken, because we will + * get two EOS buckets on the same request. + */ next->r->eos_sent = 1; } return next->frec->filter_func.out_func(next, bb); -- 2.40.0