]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: connections: Always add the xprt handshake if needed.
authorOlivier Houchard <ohouchard@haproxy.com>
Mon, 24 Jun 2019 16:19:40 +0000 (18:19 +0200)
committerOlivier Houchard <cognet@ci0.org>
Mon, 24 Jun 2019 17:00:16 +0000 (19:00 +0200)
commit6c6dc58da0dd868dd8ac3e8c7aa623d1bd4ddc40
treeb3b94e14bb804d17d138f61e53cd5dd3498f22fd
parentc31e2cbd28d53210b7184091bb64137c806d7957
BUG/MEDIUM: connections: Always add the xprt handshake if needed.

In connect_server(), we used to only call xprt_add_hs() if CO_FL_SEND_PROXY
was set during the function call, we would not do it if the flag was set
before connect_server() was called. The rational at the time was if the flag
was already set, then the XPRT was already present. But now the xprt_handshake
always removes itself, so we have to re-add it each time, or it wouldn't be
done if the first connection attempt failed.
While I'm there, check any non-ssl handshake flag, instead of just
CO_FL_SEND_PROXY, or we'd miss the SOCKS4 flags.

This should be backported to 2.0.
src/backend.c