]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MEDIUM: receivers: add an rx_unbind() method in the protocols
authorWilly Tarreau <w@1wt.eu>
Fri, 9 Oct 2020 14:32:08 +0000 (16:32 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 9 Oct 2020 16:44:36 +0000 (18:44 +0200)
commitf58b8db47be6a85468e95c1708441f68f63f7ce9
treeb7dcc21e194e186503c5f5cf751555044883be56
parent18c20d28d7efc4ef5b48ce6bd1984ca0c356ff08
MEDIUM: receivers: add an rx_unbind() method in the protocols

This is used as a generic way to unbind a receiver at the end of
do_unbind_listener(). This allows to considerably simplify that function
since we can now let the protocol perform the cleanup. The generic code
was moved to sock.c, along with the conditional rx_disable() call. Now
the code also supports that the ->disable() function of the protocol
which acts on the listener performs the close itself and adjusts the
RX_F_BUOND flag accordingly.
include/haproxy/protocol-t.h
include/haproxy/sock.h
src/listener.c
src/proto_sockpair.c
src/proto_tcp.c
src/proto_udp.c
src/proto_uxst.c
src/sock.c