From cd67bffd26561e748f897efba589425ac659f1d9 Mon Sep 17 00:00:00 2001 From: Christopher Faulet Date: Fri, 14 Jun 2019 16:54:15 +0200 Subject: [PATCH] BUG/MINOR: mux-h1: Wake busy mux for I/O when message is fully sent If a mux is in busy mode when the outgoing EOM is consummed, it is important to wake it up for I/O. Because in busy mode, the mux is not subscribed for receive. Otherwise, it depends on the applicative layer to shutdown the H1 stream. Wake it up allows the mux to catch the read0 as soon as possible. This patch must be backported to 1.9. --- src/mux_h1.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/mux_h1.c b/src/mux_h1.c index 0273f881f..317f1a55c 100644 --- a/src/mux_h1.c +++ b/src/mux_h1.c @@ -1733,6 +1733,10 @@ static size_t h1_process_output(struct h1c *h1c, struct buffer *buf, size_t coun goto error; done: h1m->state = H1_MSG_DONE; + if (h1s->h1c->flags & H1C_F_IN_BUSY) { + h1s->h1c->flags &= ~H1C_F_IN_BUSY; + tasklet_wakeup(h1s->h1c->wait_event.tasklet); + } break; default: -- 2.47.3