From: Vadim Zeitlin Date: Sun, 2 Mar 2003 23:24:28 +0000 (+0000) Subject: fixed memory leak (patch 696164) X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/c5ef41d3b429d049835b6a54eb49784af9350f9a fixed memory leak (patch 696164) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@19442 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/generic/filedlgg.cpp b/src/generic/filedlgg.cpp index 9de793bd62..de20355225 100644 --- a/src/generic/filedlgg.cpp +++ b/src/generic/filedlgg.cpp @@ -1223,6 +1223,12 @@ wxFileDialog::~wxFileDialog() wxConfig::Get()->Write(wxT("/wxWindows/wxFileDialog/ShowHidden"), ms_lastShowHidden); } + + const int count = m_choice->GetCount(); + for ( int i = 0; i < count; i++ ) + { + delete (wxString *)m_choice->GetClientData(i); + } } int wxFileDialog::ShowModal()