summaryrefslogtreecommitdiff
path: root/cppu
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@suse.cz>2011-03-23 16:59:59 +0100
committerJan Holesovsky <kendy@suse.cz>2011-03-23 16:59:59 +0100
commitad669b8d2356b1f53c11c33ccb51803fd3ea49fe (patch)
tree605a882022093cc2eb32e4af9c06cd75befea795 /cppu
parent5f3b360f26fb05b2c1b6666321359346f2ddb5a4 (diff)
parentc8b417d97c982736e9678264673a20d328cabd1f (diff)
Merge commit 'ooo/DEV300_m103'
Conflicts: codemaker/source/bonobowrappermaker/corbaoptions.cxx codemaker/source/cppumaker/cppuoptions.cxx codemaker/source/cunomaker/cunooptions.cxx codemaker/source/idlmaker/idloptions.cxx codemaker/source/javamaker/javaoptions.cxx cppu/source/typelib/typelib.cxx idlc/source/options.cxx offapi/com/sun/star/util/PathSubstitution.idl offapi/drafts/com/sun/star/form/ListEntryEvent.idl offapi/drafts/com/sun/star/form/XBindableValue.idl offapi/drafts/com/sun/star/form/XListEntryListener.idl offapi/drafts/com/sun/star/form/XListEntrySink.idl offapi/drafts/com/sun/star/form/XListEntrySource.idl offapi/drafts/com/sun/star/form/XValueBinding.idl registry/tools/checksingleton.cxx registry/tools/options.hxx registry/tools/regcompare.cxx registry/tools/regmerge.cxx sal/cppunittester/cppunittester.cxx sal/osl/unx/socket.c sal/osl/w32/diagnose.c sal/prj/d.lst sal/rtl/source/alloc_fini.cxx sal/rtl/source/alloc_global.c sal/rtl/source/makefile.mk
Diffstat (limited to 'cppu')
-rw-r--r--cppu/source/typelib/typelib.cxx41
1 files changed, 14 insertions, 27 deletions
diff --git a/cppu/source/typelib/typelib.cxx b/cppu/source/typelib/typelib.cxx
index e8d4a2448..c5c5f53db 100644
--- a/cppu/source/typelib/typelib.cxx
+++ b/cppu/source/typelib/typelib.cxx
@@ -342,37 +342,24 @@ TypeDescriptor_Init_Impl::~TypeDescriptor_Init_Impl() SAL_THROW( () )
delete pWeakMap;
pWeakMap = 0;
}
-#ifndef CPPU_LEAK_STATIC_DATA
#if OSL_DEBUG_LEVEL > 1
-#define MYASSERT(x) if (x != 0) fprintf(stderr, "### "#x" = %d, should be zero!!!\n", x);
- MYASSERT (nTypeDescriptionCount );
- MYASSERT( nCompoundTypeDescriptionCount );
- MYASSERT( nUnionTypeDescriptionCount );
- MYASSERT( nIndirectTypeDescriptionCount );
- MYASSERT( nArrayTypeDescriptionCount );
- MYASSERT( nEnumTypeDescriptionCount );
- MYASSERT( nInterfaceMethodTypeDescriptionCount );
- MYASSERT( nInterfaceAttributeTypeDescriptionCount );
- MYASSERT( nInterfaceTypeDescriptionCount );
- MYASSERT( nTypeDescriptionReferenceCount );
-#undef MYASSERT
-
- OSL_ASSERT( nTypeDescriptionCount == 0 );
- OSL_ASSERT( nCompoundTypeDescriptionCount == 0 );
- OSL_ASSERT( nUnionTypeDescriptionCount == 0 );
- OSL_ASSERT( nIndirectTypeDescriptionCount == 0 );
- OSL_ASSERT( nArrayTypeDescriptionCount == 0 );
- OSL_ASSERT( nEnumTypeDescriptionCount == 0 );
- OSL_ASSERT( nInterfaceMethodTypeDescriptionCount == 0 );
- OSL_ASSERT( nInterfaceAttributeTypeDescriptionCount == 0 );
- OSL_ASSERT( nInterfaceTypeDescriptionCount == 0 );
- OSL_ASSERT( nTypeDescriptionReferenceCount == 0 );
-
- OSL_ASSERT( !pCallbacks || pCallbacks->empty() );
+ OSL_ENSURE( !nTypeDescriptionCount );
+ OSL_ENSURE( !nCompoundTypeDescriptionCount );
+ OSL_ENSURE( !nUnionTypeDescriptionCount );
+ OSL_ENSURE( !nIndirectTypeDescriptionCount );
+ OSL_ENSURE( !nArrayTypeDescriptionCount );
+ OSL_ENSURE( !nEnumTypeDescriptionCount );
+ OSL_ENSURE( !nInterfaceMethodTypeDescriptionCount );
+ OSL_ENSURE( !nInterfaceAttributeTypeDescriptionCount );
+ OSL_ENSURE( !nInterfaceTypeDescriptionCount );
+ OSL_ENSURE( !nTypeDescriptionReferenceCount );
+
+ OSL_ENSURE( !pCallbacks || pCallbacks->empty() );
#endif
+
delete pCallbacks;
pCallbacks = 0;
-#endif // CPPU_LEAK_STATIC_DATA
+
if( pMutex )
{
delete pMutex;