From: ptv Date: Wed, 5 Jul 2006 09:44:20 +0000 (+0000) Subject: remove memory leak on myFormats QPtrList X-Git-Tag: LAST_STABLE_VERSION_21_09_2006_ON_3_2_0~61 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=28a2dcbdb862e4d331b58f0fc368a67fbe8c381e;p=modules%2Fgui.git remove memory leak on myFormats QPtrList --- diff --git a/src/Qtx/QtxResourceMgr.cxx b/src/Qtx/QtxResourceMgr.cxx index d5b3e3a6f..736e74137 100644 --- a/src/Qtx/QtxResourceMgr.cxx +++ b/src/Qtx/QtxResourceMgr.cxx @@ -879,9 +879,11 @@ QtxResourceMgr::~QtxResourceMgr() QStringList prefList = myTranslator.keys(); for ( QStringList::const_iterator it = prefList.begin(); it != prefList.end(); ++it ) removeTranslators( *it ); - for ( ResListIterator it( myResources ); it.current(); ++it ) - delete it.current(); + for ( ResListIterator resIt( myResources ); resIt.current(); ++resIt ) + delete resIt.current(); myResources.clear(); + for ( FormatListIterator formIt( myFormats ); formIt.current(); ++formIt ) + delete formIt.current(); } /*!