]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MEDIUM: connection: panic when calling FD-specific functions on FD-less conns
authorWilly Tarreau <w@1wt.eu>
Mon, 11 Apr 2022 16:07:03 +0000 (18:07 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 11 Apr 2022 17:31:47 +0000 (19:31 +0200)
commit07ecfc5e88b045b647860358bbdb1ddda46e3cd7
tree02f289425eed9f60536d99fa66f371b9237e2710
parente22267971b7c1a09cfb95fba6e300d32ee01ac70
MEDIUM: connection: panic when calling FD-specific functions on FD-less conns

Certain functions cannot be called on an FD-less conn because they are
normally called as part of the protocol-specific setup/teardown sequence.
Better place a few BUG_ON() to make sure none of them is called in other
situations. If any of them would trigger in ambiguous conditions, it would
always be possible to replace it with an error.
include/haproxy/connection.h
src/check.c
src/connection.c
src/raw_sock.c
src/sock.c
src/ssl_sock.c