From 86e04dd564ee58dc3a5d72da99489518b5497ca3 Mon Sep 17 00:00:00 2001 From: Amos Jeffries Date: Wed, 27 Mar 2013 21:16:05 -0600 Subject: [PATCH] Fix memory leaks in ConnStateData pinning ConnStateData does not cleanup any of the pinning child structure fields. This results in a leak of pinned host and peer details. Run the full un-pin cleanup operation from ConnStateData::swanSong in order to clean up all the pinning state instead of just the release the Comm::Connection. --- src/client_side.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/client_side.cc b/src/client_side.cc index 626018be25..25ed433d67 100644 --- a/src/client_side.cc +++ b/src/client_side.cc @@ -809,9 +809,7 @@ ConnStateData::swanSong() } #endif - if (Comm::IsConnOpen(pinning.serverConnection)) - pinning.serverConnection->close(); - pinning.serverConnection = NULL; + unpinConnection(); if (Comm::IsConnOpen(clientConnection)) clientConnection->close(); -- 2.47.3