From: Vadim Zeitlin Date: Sat, 27 Apr 2002 22:37:28 +0000 (+0000) Subject: really fixed memory leak in wxLogChain X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/e95f8fde77a7e5951b742db0ea50de4d6f1118ff really fixed memory leak in wxLogChain git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15289 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/common/log.cpp b/src/common/log.cpp index 4c58a331e2..9a182465b8 100644 --- a/src/common/log.cpp +++ b/src/common/log.cpp @@ -770,7 +770,10 @@ wxLogChain::wxLogChain(wxLog *logger) wxLogChain::~wxLogChain() { - delete m_logNew; + delete m_logOld; + + if ( m_logNew != this ) + delete m_logNew; } void wxLogChain::SetLog(wxLog *logger)