From: Olivier Houchard Date: Thu, 27 Dec 2018 17:59:46 +0000 (+0100) Subject: BUG/MEDIUM: servers: Flag the stream_interface on handshake error. X-Git-Tag: v2.0-dev1~310 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=4f41751ad21d89ca1e93e6fd6dca209f0cc66573;p=thirdparty%2Fhaproxy.git BUG/MEDIUM: servers: Flag the stream_interface on handshake error. When creating a new outgoing connection, if we're using ALPN and waiting for the handshake completion to choose the mux, and for some reason the handshake failed, add the SI_FL_ERR flag to the stream_interface, so that process_streams() knows the connection failed, and can attempt to retry, instead of just hanging. This should be backported to 1.9. --- diff --git a/src/backend.c b/src/backend.c index babe96eb86..c4711ead88 100644 --- a/src/backend.c +++ b/src/backend.c @@ -1089,6 +1089,8 @@ fail: conn_stop_tracking(conn); conn_full_close(conn); conn_free(conn); + /* Let process_stream know it went wrong */ + s->si[1].flags |= SI_FL_ERR; return -1; } #endif