From 33e6e16fbc58c7f752c6b6899f46839f057ca2b5 Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Sun, 1 Mar 2020 15:31:24 +0100 Subject: [PATCH] handle_established_connection(): Don't mess with csp->ssl_with_(server|client)_is_opened This was a mismerge in 2111876638. The original code did it in chat() were it doesn't hurt. Actually we don't need to do it at all, as the variables are initialized to 0. Zeroing the variables in handle_established_connection() caused memory leaks as close_server_ssl_connection() and close_client_ssl_connection() returned early, Sponsored by: Robert Klemme --- jcc.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/jcc.c b/jcc.c index 3809f40c..f142996e 100644 --- a/jcc.c +++ b/jcc.c @@ -2410,13 +2410,6 @@ static void handle_established_connection(struct client_state *csp) int use_ssl_tunnel = 0; csp->dont_verify_certificate = 0; - /* - * Preset flags informing if SSL connections with server or client - * are opened or closed - */ - csp->ssl_with_server_is_opened = 0; - csp->ssl_with_client_is_opened = 0; - if (csp->http->ssl && !(csp->action->flags & ACTION_HTTPS_INSPECTION)) { /* Pass encrypted content without filtering. */ -- 2.39.2