diff --git a/src/mux_h1.c b/src/mux_h1.c index a00ac60f2..1f8cad245 100644 --- a/src/mux_h1.c +++ b/src/mux_h1.c @@ -990,6 +990,8 @@ static int h1_init(struct connection *conn, struct proxy *proxy, struct session tasklet_free(h1c->wait_event.tasklet); pool_free(pool_head_h1c, h1c); fail_h1c: + if (!conn_is_back(conn)) + LIST_DEL_INIT(&conn->stopping_list); conn->ctx = conn_ctx; // restore saved context TRACE_DEVEL("leaving in error", H1_EV_H1C_NEW|H1_EV_H1C_END|H1_EV_H1C_ERR); return -1; diff --git a/src/mux_h2.c b/src/mux_h2.c index 6338cf02c..ddc19c176 100644 --- a/src/mux_h2.c +++ b/src/mux_h2.c @@ -1042,6 +1042,8 @@ static int h2_init(struct connection *conn, struct proxy *prx, struct session *s tasklet_free(h2c->wait_event.tasklet); pool_free(pool_head_h2c, h2c); fail_no_h2c: + if (!conn_is_back(conn)) + LIST_DEL_INIT(&conn->stopping_list); conn->ctx = conn_ctx; /* restore saved ctx */ TRACE_DEVEL("leaving in error", H2_EV_H2C_NEW|H2_EV_H2C_END|H2_EV_H2C_ERR); return -1;