Skip to content

Commit

Permalink
* Fixed input handling for requests without body that nevertheless try
Browse files Browse the repository at this point in the history
   to read one (e.g. mod_cgid handling) to deliver at least an EOS bucket
   before signalling an EOF.
  • Loading branch information
Stefan Eissing committed Nov 11, 2021
1 parent a42ad0a commit 0f1d3c4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
* Fixed input handling for requests without body that nevertheless try
to read one (e.g. mod_cgid handling) to deliver at least an EOS bucket
before signalling an EOF.
* A regression in v1.15.24 was fixed that could lead to httpd child
processes not being terminated on a graceful reload or when reaching
MaxConnectionsPerChild. When unprocessed h2 requests were queued at
Expand Down
8 changes: 4 additions & 4 deletions mod_http2/h2_c2.c
Original file line number Diff line number Diff line change
Expand Up @@ -269,14 +269,14 @@ static apr_status_t h2_c2_filter_in(ap_filter_t* f,
return APR_ECONNABORTED;
}

if (!conn_ctx->beam_in) {
return APR_EOF;
}

if (!fctx) {
fctx = apr_pcalloc(f->c->pool, sizeof(*fctx));
f->ctx = fctx;
fctx->bb = apr_brigade_create(f->c->pool, f->c->bucket_alloc);
if (!conn_ctx->beam_in) {
b = apr_bucket_eos_create(f->c->bucket_alloc);
APR_BRIGADE_INSERT_TAIL(fctx->bb, b);
}
}

/* Cleanup brigades from those nasty 0 length non-meta buckets
Expand Down

0 comments on commit 0f1d3c4

Please sign in to comment.