From 4e74155466e0805ad18ce587ffc68df9594fecde Mon Sep 17 00:00:00 2001 From: Christopher Faulet Date: Wed, 30 Sep 2020 13:47:09 +0200 Subject: [PATCH] MINOR: mux-h1: Update session idle duration when data are received The session idle duration is set if not already done when data are received. For now, this value is still unused. --- src/mux_h1.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mux_h1.c b/src/mux_h1.c index cc34bba..cb1addd 100644 --- a/src/mux_h1.c +++ b/src/mux_h1.c @@ -2228,6 +2228,8 @@ static int h1_process(struct h1c * h1c) if (b_data(&h1c->ibuf) && h1s->csinfo.t_idle == -1) h1s->csinfo.t_idle = tv_ms_elapsed(&h1s->csinfo.tv_create, &now) - h1s->csinfo.t_handshake; + if (b_data(&h1c->ibuf) && h1s->sess->t_idle == -1) + h1s->sess->t_idle = tv_ms_elapsed(&h1s->sess->tv_accept, &now) - h1s->sess->t_handshake; if (conn_xprt_read0_pending(conn)) { h1s->flags |= H1S_F_REOS; -- 1.7.10.4