MINOR: protocol: add a new pair of enable/disable methods for listeners
authorWilly Tarreau <w@1wt.eu>
Fri, 25 Sep 2020 17:27:39 +0000 (19:27 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 9 Oct 2020 09:27:30 +0000 (11:27 +0200)
commit5ddf1ce9c479480e2b5976f340714e29831ed2ea
tree71315892e0ccb0b210ac00d4d127a557bfeec94b
parent686fa3db5086c6deb07152915ff4f2283bb99352
MINOR: protocol: add a new pair of enable/disable methods for listeners

These methods will be used to enable/disable accepting new connections
so that listeners do not play with FD directly anymore. Since all the
currently supported protocols work on socket for now, these are identical
to the rx_enable/rx_disable functions. However they were not defined in
sock.c since it's likely that some will quickly start to differ. At the
moment they're not used.

We have to take care of fd_updt before calling fd_{want,stop}_recv()
because it's allocated fairly late in the boot process and some such
functions may be called very early (e.g. to stop a disabled frontend's
listeners).
include/haproxy/protocol-t.h
src/proto_sockpair.c
src/proto_tcp.c
src/proto_udp.c
src/proto_uxst.c