From: Christopher Faulet Date: Fri, 15 Apr 2022 08:57:09 +0000 (+0200) Subject: BUG/MEDIUM: connection: Don't crush context pointer location if it is a CS X-Git-Tag: v2.6-dev6~9 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2bb5edcf19cc0666464a91b5f13070dd8af2a415;p=thirdparty%2Fhaproxy.git BUG/MEDIUM: connection: Don't crush context pointer location if it is a CS The issue only concerns the backend connection. The conn-stream is now owned by the stream and persists during all the stream life. Thus we must not crush it when the backend connection is released. It is 2.6-specific. No backport is needed. --- diff --git a/src/connection.c b/src/connection.c index 88e851c932..bc47ac886c 100644 --- a/src/connection.c +++ b/src/connection.c @@ -501,13 +501,6 @@ void conn_free(struct connection *conn) pool_free(pool_head_conn_hash_node, conn->hash_node); conn->hash_node = NULL; - /* By convention we always place a NULL where the ctx points to if the - * mux is null. It may have been used to store the connection as a - * conn-stream's end point for example. - */ - if (conn->ctx != NULL && conn->mux == NULL) - *(void **)conn->ctx = NULL; - conn_force_unsubscribe(conn); pool_free(pool_head_connection, conn); }