]> git.ipfire.org Git - thirdparty/shairport-sync.git/commitdiff
Fix another memory leak.
authorMike Brady <4265913+mikebrady@users.noreply.github.com>
Tue, 7 Dec 2021 20:34:23 +0000 (20:34 +0000)
committerMike Brady <4265913+mikebrady@users.noreply.github.com>
Tue, 7 Dec 2021 20:34:23 +0000 (20:34 +0000)
rtsp.c

diff --git a/rtsp.c b/rtsp.c
index 4396a3637bf3f00c7c1a7d98f68c8108175e9e63..2f7da6c5bad541197146c6fc01cd1650807d53fb 100644 (file)
--- 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);
 }