From: Vadim Zeitlin Date: Fri, 6 Dec 2002 23:55:55 +0000 (+0000) Subject: fixed 3 infinite loops -- the person who tested this code must have had a lot of... X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/6eccc0c485e57fe27fc56673f4f4dd191a09b2e6 fixed 3 infinite loops -- the person who tested this code must have had a lot of patience (bug 645761) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18080 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/common/dynload.cpp b/src/common/dynload.cpp index 4c86a5e19a..240c4e0c55 100644 --- a/src/common/dynload.cpp +++ b/src/common/dynload.cpp @@ -469,7 +469,7 @@ void wxPluginLibrary::RegisterModules() wxASSERT_MSG( m_linkcount == 1, _T("RegisterModules should only be called for the first load") ); - for(wxClassInfo *info = m_after; info != m_before; info = info->m_next) + for ( wxClassInfo *info = m_after; info != m_before; info = info->m_next) { if( info->IsKindOf(CLASSINFO(wxModule)) ) { @@ -484,7 +484,9 @@ void wxPluginLibrary::RegisterModules() // FIXME: Likewise this is (well was) very similar to InitializeModules() - for(wxModuleList::Node *node = m_wxmodules.GetFirst(); node; node->GetNext()) + for ( wxModuleList::Node *node = m_wxmodules.GetFirst(); + node; + node = node->GetNext()) { if( !node->GetData()->Init() ) { @@ -515,10 +517,10 @@ void wxPluginLibrary::UnregisterModules() { wxModuleList::Node *node; - for(node = m_wxmodules.GetFirst(); node; node->GetNext()) + for ( node = m_wxmodules.GetFirst(); node; node = node->GetNext() ) node->GetData()->Exit(); - for(node = m_wxmodules.GetFirst(); node; node->GetNext()) + for ( node = m_wxmodules.GetFirst(); node; node = node->GetNext() ) wxModule::UnregisterModule( node->GetData() ); m_wxmodules.DeleteContents(TRUE);