]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: connection: prepare init code paths for active reverse
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Wed, 23 Aug 2023 16:02:51 +0000 (18:02 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 24 Aug 2023 15:02:37 +0000 (17:02 +0200)
commitb781a1bb09f868cc1ab38a45acf06ef398695718
treecbb54f5fdb8bf95508eb45b5fdfb0028fc7b774a
parent0747e493a0f3c59d14cd352926a6f628377a8e7f
MINOR: connection: prepare init code paths for active reverse

When an active reverse connection is initialized, it has no stream-conn
attached to it contrary to other backend connections. This forces to add
extra check on stream existence in conn_create_mux() and h2_init().

There is also extra checks required for session_accept_fd() after
reverse and accept is done. This is because contrary to other frontend
connections, reversed connections have already initialized their mux and
transport layers. This forces us to skip the majority of
session_accept_fd() initialization part.

Finally, if session_accept_fd() is interrupted due to an early error, a
reverse connection cannot be freed directly or else mux will remain
alone. Instead, the mux destroy callback is used to free all connection
elements properly.
src/connection.c
src/mux_h2.c
src/session.c