summaryrefslogtreecommitdiff
path: root/cppuhelper
diff options
context:
space:
mode:
Diffstat (limited to 'cppuhelper')
-rw-r--r--cppuhelper/source/component.cxx2
-rw-r--r--cppuhelper/source/component_context.cxx6
-rw-r--r--cppuhelper/source/exc_thrower.cxx10
-rw-r--r--cppuhelper/source/implbase.cxx4
-rw-r--r--cppuhelper/source/interfacecontainer.cxx8
-rw-r--r--cppuhelper/source/tdmgr.cxx14
-rw-r--r--cppuhelper/source/weak.cxx10
7 files changed, 27 insertions, 27 deletions
diff --git a/cppuhelper/source/component.cxx b/cppuhelper/source/component.cxx
index fdff1a21bab8..b9b97d953e8b 100644
--- a/cppuhelper/source/component.cxx
+++ b/cppuhelper/source/component.cxx
@@ -101,7 +101,7 @@ void OComponentHelper::release() throw()
}
// only the alive ref holds the object
- OSL_ASSERT( m_refCount == 1 );
+ assert( m_refCount == 1 );
// destroy the object if xHoldAlive decrement the refcount to 0
return;
}
diff --git a/cppuhelper/source/component_context.cxx b/cppuhelper/source/component_context.cxx
index 2df1b495689c..d3bbeea5f3b9 100644
--- a/cppuhelper/source/component_context.cxx
+++ b/cppuhelper/source/component_context.cxx
@@ -85,7 +85,7 @@ class DisposingForwarder
explicit DisposingForwarder( Reference< lang::XComponent > const & xTarget )
: m_xTarget( xTarget )
{
- OSL_ASSERT( m_xTarget.is() );
+ assert( m_xTarget.is() );
}
public:
// listens at source for disposing, then disposes target
@@ -532,7 +532,7 @@ ComponentContext::ComponentContext(
UNO_QUERY );
// patch DefaultContext property of new one
Reference< beans::XPropertySet > xProps( m_xSMgr, UNO_QUERY );
- OSL_ASSERT( xProps.is() );
+ assert( xProps.is() );
if (xProps.is())
{
Reference< XComponentContext > xThis( this );
@@ -545,7 +545,7 @@ ComponentContext::ComponentContext(
throw;
}
osl_atomic_decrement( &m_refCount );
- OSL_ASSERT( m_xSMgr.is() );
+ assert( m_xSMgr.is() );
}
}
}
diff --git a/cppuhelper/source/exc_thrower.cxx b/cppuhelper/source/exc_thrower.cxx
index 8bd5084c7e8c..de05ab727215 100644
--- a/cppuhelper/source/exc_thrower.cxx
+++ b/cppuhelper/source/exc_thrower.cxx
@@ -75,7 +75,7 @@ void SAL_CALL ExceptionThrower_dispatch(
uno_Interface * pUnoI, typelib_TypeDescription const * pMemberType,
void * pReturn, void * pArgs [], uno_Any ** ppException )
{
- OSL_ASSERT( pMemberType->eTypeClass == typelib_TypeClass_INTERFACE_METHOD );
+ assert( pMemberType->eTypeClass == typelib_TypeClass_INTERFACE_METHOD );
switch (reinterpret_cast< typelib_InterfaceMemberTypeDescription * >(
const_cast< typelib_TypeDescription * >( pMemberType ) )->
@@ -109,13 +109,13 @@ void SAL_CALL ExceptionThrower_dispatch(
case 3: // throwException()
{
uno_Any * pAny = static_cast< uno_Any * >( pArgs[ 0 ] );
- OSL_ASSERT( pAny->pType->eTypeClass == typelib_TypeClass_EXCEPTION );
+ assert( pAny->pType->eTypeClass == typelib_TypeClass_EXCEPTION );
uno_type_any_construct( *ppException, pAny->pData, pAny->pType, nullptr );
break;
}
default:
{
- OSL_ASSERT( false );
+ assert( false );
RuntimeException exc( "not implemented!" );
uno_type_any_construct(
*ppException, &exc, cppu::UnoType<decltype(exc)>::get().getTypeLibType(), nullptr );
@@ -198,7 +198,7 @@ void SAL_CALL throwException( Any const & exc )
reinterpret_cast< void ** >( &xThrower ),
static_cast< uno_Interface * >( &theExceptionThrower::get() ),
ExceptionThrower::getCppuType() );
- OSL_ASSERT( xThrower.is() );
+ assert( xThrower.is() );
xThrower->throwException( exc );
}
@@ -226,7 +226,7 @@ Any SAL_CALL getCaughtException()
cpp2uno.mapInterface(
reinterpret_cast< void ** >( &unoI.m_pUnoI ),
static_cast< XExceptionThrower * >( &theExceptionThrower::get() ), pTD );
- OSL_ASSERT( unoI.is() );
+ assert( unoI.is() );
typelib_TypeDescription * pMemberTD = nullptr;
TYPELIB_DANGER_GET(
diff --git a/cppuhelper/source/implbase.cxx b/cppuhelper/source/implbase.cxx
index 6118ccb79fc1..596508e213a8 100644
--- a/cppuhelper/source/implbase.cxx
+++ b/cppuhelper/source/implbase.cxx
@@ -82,7 +82,7 @@ void WeakComponentImplHelperBase::release()
exc.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
static_cast<void>(exc);
}
- OSL_ASSERT( rBHelper.bDisposed );
+ assert( rBHelper.bDisposed );
}
OWeakObject::release();
}
@@ -209,7 +209,7 @@ void WeakAggComponentImplHelperBase::release()
exc.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
static_cast<void>(exc);
}
- OSL_ASSERT( rBHelper.bDisposed );
+ assert( rBHelper.bDisposed );
}
OWeakAggObject::release();
}
diff --git a/cppuhelper/source/interfacecontainer.cxx b/cppuhelper/source/interfacecontainer.cxx
index 2eb7197bf9e6..0571c4c87e66 100644
--- a/cppuhelper/source/interfacecontainer.cxx
+++ b/cppuhelper/source/interfacecontainer.cxx
@@ -126,14 +126,14 @@ void OInterfaceIteratorHelper::remove()
{
if( bIsList )
{
- OSL_ASSERT( nRemain >= 0 &&
+ assert( nRemain >= 0 &&
nRemain < aData.pAsSequence->getLength() );
XInterface * p = aData.pAsSequence->getConstArray()[nRemain].get();
rCont.removeInterface( * reinterpret_cast< const Reference< XInterface > * >( &p ) );
}
else
{
- OSL_ASSERT( 0 == nRemain );
+ assert( 0 == nRemain );
rCont.removeInterface( * reinterpret_cast< const Reference< XInterface > * >(&aData.pAsInterface));
}
}
@@ -195,7 +195,7 @@ void OInterfaceContainerHelper::copyAndResetInUse()
sal_Int32 OInterfaceContainerHelper::addInterface( const Reference<XInterface> & rListener )
{
- OSL_ASSERT( rListener.is() );
+ assert( rListener.is() );
MutexGuard aGuard( rMutex );
if( bInUse )
copyAndResetInUse();
@@ -226,7 +226,7 @@ sal_Int32 OInterfaceContainerHelper::addInterface( const Reference<XInterface> &
sal_Int32 OInterfaceContainerHelper::removeInterface( const Reference<XInterface> & rListener )
{
- OSL_ASSERT( rListener.is() );
+ assert( rListener.is() );
MutexGuard aGuard( rMutex );
if( bInUse )
copyAndResetInUse();
diff --git a/cppuhelper/source/tdmgr.cxx b/cppuhelper/source/tdmgr.cxx
index 02da05163732..9a5b7f6cba58 100644
--- a/cppuhelper/source/tdmgr.cxx
+++ b/cppuhelper/source/tdmgr.cxx
@@ -155,11 +155,11 @@ inline static typelib_TypeDescription * createCTD(
Reference< XStructTypeDescription > templateDesc(
access->getByHierarchicalName(aTypeName.copy(0, i)),
UNO_QUERY_THROW);
- OSL_ASSERT(
+ assert(
templateDesc->getTypeParameters().getLength()
== xType->getTypeArguments().getLength());
templateMemberTypes = templateDesc->getMemberTypes();
- OSL_ASSERT(templateMemberTypes.getLength() == nMembers);
+ assert(templateMemberTypes.getLength() == nMembers);
}
sal_Int32 nPos;
@@ -212,7 +212,7 @@ inline static typelib_TypeDescription * createCTD(
xAttribute->getGetExceptions() );
for (sal_Int32 i = 0; i != getExcs.getLength(); ++i)
{
- OSL_ASSERT( getExcs[i].is() );
+ assert( getExcs[i].is() );
getExc.push_back( getExcs[i]->getName().pData );
}
std::vector< rtl_uString * > setExc;
@@ -220,7 +220,7 @@ inline static typelib_TypeDescription * createCTD(
xAttribute->getSetExceptions() );
for (sal_Int32 i = 0; i != setExcs.getLength(); ++i)
{
- OSL_ASSERT( setExcs[i].is() );
+ assert( setExcs[i].is() );
setExc.push_back( setExcs[i]->getName().pData );
}
typelib_typedescription_newExtendedInterfaceAttribute(
@@ -322,7 +322,7 @@ inline static typelib_TypeDescription * createCTD(
new typelib_TypeDescription *[nBases]);
for (sal_Int32 i = 0; i < nBases; ++i) {
typelib_TypeDescription * p = createCTD(access, aBases[i]);
- OSL_ASSERT(
+ assert(
!TYPELIB_TYPEDESCRIPTIONREFERENCE_ISREALLYWEAK(p->eTypeClass));
typelib_typedescription_register(&p);
aBaseTypes[i] = p;
@@ -380,7 +380,7 @@ inline static typelib_TypeDescription * createCTD( const Reference< XEnumTypeDes
{
OUString aTypeName( xType->getName() );
Sequence< OUString > aNames( xType->getEnumNames() );
- OSL_ASSERT( sizeof(OUString) == sizeof(rtl_uString *) ); // !!!
+ assert( sizeof(OUString) == sizeof(rtl_uString *) ); // !!!
Sequence< sal_Int32 > aValues( xType->getEnumValues() );
typelib_typedescription_newEnum(
@@ -621,7 +621,7 @@ public:
void EventListenerImpl::disposing( lang::EventObject const & rEvt )
{
if (rEvt.Source != m_xTDMgr) {
- OSL_ASSERT(false);
+ assert(false);
}
// deregister of c typelib callback
::typelib_typedescription_revokeCallback( m_xTDMgr.get(), typelib_callback );
diff --git a/cppuhelper/source/weak.cxx b/cppuhelper/source/weak.cxx
index b52634b26ecc..981867ec5162 100644
--- a/cppuhelper/source/weak.cxx
+++ b/cppuhelper/source/weak.cxx
@@ -383,7 +383,7 @@ OWeakRefListener::OWeakRefListener(const Reference< XInterface >& xInt)
}
}
}
- catch (RuntimeException &) { OSL_ASSERT( false ); } // assert here, but no unexpected()
+ catch (RuntimeException &) { assert( false ); } // assert here, but no unexpected()
osl_atomic_decrement( &m_aRefCount );
}
@@ -397,7 +397,7 @@ OWeakRefListener::~OWeakRefListener()
m_XWeakConnectionPoint->removeReference(static_cast<XReference*>(this));
}
}
- catch (RuntimeException &) { OSL_ASSERT( false ); } // assert here, but no unexpected()
+ catch (RuntimeException &) { assert( false ); } // assert here, but no unexpected()
}
// XInterface
@@ -471,7 +471,7 @@ void WeakReferenceHelper::clear()
m_pImpl = nullptr;
}
}
- catch (RuntimeException &) { OSL_ASSERT( false ); } // assert here, but no unexpected()
+ catch (RuntimeException &) { assert( false ); } // assert here, but no unexpected()
}
WeakReferenceHelper& WeakReferenceHelper::operator=(const WeakReferenceHelper& rWeakRef)
@@ -504,7 +504,7 @@ WeakReferenceHelper::operator= (const Reference< XInterface > & xInt)
m_pImpl->acquire();
}
}
- catch (RuntimeException &) { OSL_ASSERT( false ); } // assert here, but no unexpected()
+ catch (RuntimeException &) { assert( false ); } // assert here, but no unexpected()
return *this;
}
@@ -530,7 +530,7 @@ Reference< XInterface > WeakReferenceHelper::get() const
}
catch (RuntimeException &)
{
- OSL_ASSERT( false );
+ assert( false );
} // assert here, but no unexpected()
return Reference< XInterface >();