]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MINOR: mux_h2: don't lose the leaving trace in h2_io_cb()
authorWilly Tarreau <w@1wt.eu>
Sat, 27 Jun 2020 22:31:13 +0000 (00:31 +0200)
committerWilly Tarreau <w@1wt.eu>
Sat, 27 Jun 2020 22:34:23 +0000 (00:34 +0200)
Commit cd4159f ("MEDIUM: mux_h2: Implement the takeover() method.")
added a return in the middle of the function, and as usual with such
stray return statements, some unrolling was lost. Here it's only the
TRACE_LEAVE() call, so it's mostly harmless. That's 2.2 only, no
backport is needed.

src/mux_h2.c

index 9928b32c7607a3125df27157a5fd3629d0fa73c3..bec6af004468675891da51bc1427d156133841cd 100644 (file)
@@ -3532,7 +3532,7 @@ static struct task *h2_io_cb(struct task *t, void *ctx, unsigned short status)
                 */
                HA_SPIN_UNLOCK(OTHER_LOCK, &toremove_lock[tid]);
                tasklet_free(tl);
-               return NULL;
+               goto leave;
        }
        h2c = ctx;
        conn = h2c->conn;
@@ -3570,6 +3570,7 @@ static struct task *h2_io_cb(struct task *t, void *ctx, unsigned short status)
                        MT_LIST_ADDQ(&srv->idle_conns[tid], &conn->list);
        }
 
+leave:
        TRACE_LEAVE(H2_EV_H2C_WAKE);
        return NULL;
 }