From 31a34ae6846f464237f4cbb2293b1bbdd8b070bf Mon Sep 17 00:00:00 2001 From: Mike Brady <4265913+mikebrady@users.noreply.github.com> Date: Tue, 7 Dec 2021 20:34:23 +0000 Subject: [PATCH] Fix another memory leak. --- rtsp.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/rtsp.c b/rtsp.c index 4396a363..2f7da6c5 100644 --- a/rtsp.c +++ b/rtsp.c @@ -2559,6 +2559,10 @@ void handle_teardown(rtsp_conn_info *conn, __attribute__((unused)) rtsp_message conn->connection_number); resp->respcode = 451; } + if (conn->dacp_active_remote != NULL) { + free(conn->dacp_active_remote); + conn->dacp_active_remote = NULL; + } debug(1,"Bogus exit for valgrind -- remember to comment it out!."); exit(EXIT_SUCCESS); }