summaryrefslogtreecommitdiff
path: root/unotools/source/config/configmgr.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'unotools/source/config/configmgr.cxx')
-rw-r--r--unotools/source/config/configmgr.cxx14
1 files changed, 10 insertions, 4 deletions
diff --git a/unotools/source/config/configmgr.cxx b/unotools/source/config/configmgr.cxx
index 4f83a861b416..7f411eab6803 100644
--- a/unotools/source/config/configmgr.cxx
+++ b/unotools/source/config/configmgr.cxx
@@ -122,17 +122,23 @@ ConfigManager::~ConfigManager()
{
//check list content -> should be empty!
#if OSL_DEBUG_LEVEL > 0
- OSL_ENSURE(pMgrImpl->aItemList.empty(), "some ConfigItems are still alive");
-#endif
if(!pMgrImpl->aItemList.empty())
{
ConfigItemList::iterator aListIter;
- for(aListIter = pMgrImpl->aItemList.begin(); aListIter != pMgrImpl->aItemList.end(); ++aListIter)
+ for (aListIter = pMgrImpl->aItemList.begin(); aListIter != pMgrImpl->aItemList.end(); ++aListIter)
{
ConfigItemListEntry_Impl& rEntry = *aListIter;
-#if OSL_DEBUG_LEVEL > 0
fprintf(stderr, "Dangling config item of %s\n", rtl::OUStringToOString(rEntry.pConfigItem->GetSubTreeName(), RTL_TEXTENCODING_UTF8).getStr());
+ }
+ }
#endif
+ OSL_ENSURE(pMgrImpl->aItemList.empty(), "some ConfigItems are still alive");
+ if(!pMgrImpl->aItemList.empty())
+ {
+ ConfigItemList::iterator aListIter;
+ for(aListIter = pMgrImpl->aItemList.begin(); aListIter != pMgrImpl->aItemList.end(); ++aListIter)
+ {
+ ConfigItemListEntry_Impl& rEntry = *aListIter;
rEntry.pConfigItem->ReleaseConfigMgr();
}
pMgrImpl->aItemList.erase(pMgrImpl->aItemList.begin(), pMgrImpl->aItemList.end());