summaryrefslogtreecommitdiffstats
path: root/modules/http2
diff options
context:
space:
mode:
authorStefan Eissing <icing@apache.org>2018-04-11 10:30:25 +0200
committerStefan Eissing <icing@apache.org>2018-04-11 10:30:25 +0200
commitc2be1676a8f8195fba2e39abb91adcc2281a5e9d (patch)
tree1733290654de5d8ea6bf7db36890ffd4215e2c14 /modules/http2
parentUpdate prettify.js (diff)
downloadapache2-c2be1676a8f8195fba2e39abb91adcc2281a5e9d.tar.xz
apache2-c2be1676a8f8195fba2e39abb91adcc2281a5e9d.zip
On the trunk:
mod_http2: always wake up any conditional waits when streams are aborted. Fixes race conditions where timeouts would trigger instead. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1828879 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '')
-rw-r--r--modules/http2/h2_bucket_beam.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/modules/http2/h2_bucket_beam.c b/modules/http2/h2_bucket_beam.c
index 6b6750d1fa..7653ec1092 100644
--- a/modules/http2/h2_bucket_beam.c
+++ b/modules/http2/h2_bucket_beam.c
@@ -550,6 +550,7 @@ static void recv_buffer_cleanup(h2_bucket_beam *beam, h2_beam_lock *bl)
apr_brigade_destroy(bb);
if (bl) enter_yellow(beam, bl);
+ apr_thread_cond_broadcast(beam->change);
if (beam->cons_ev_cb) {
beam->cons_ev_cb(beam->cons_ctx, beam);
}
@@ -707,12 +708,10 @@ void h2_beam_abort(h2_bucket_beam *beam)
h2_beam_lock bl;
if (beam && enter_yellow(beam, &bl) == APR_SUCCESS) {
- if (!beam->aborted) {
- beam->aborted = 1;
- r_purge_sent(beam);
- h2_blist_cleanup(&beam->send_list);
- report_consumption(beam, &bl);
- }
+ beam->aborted = 1;
+ r_purge_sent(beam);
+ h2_blist_cleanup(&beam->send_list);
+ report_consumption(beam, &bl);
apr_thread_cond_broadcast(beam->change);
leave_yellow(beam, &bl);
}