summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@collabora.com>2015-03-24 12:01:07 +0000
committerMichael Meeks <michael.meeks@collabora.com>2015-04-10 13:07:24 +0100
commit554be83e0f30d7c47f84195b1677ee1304fe2a34 (patch)
tree068561d4a2e3e5b30f354bad5e7a8419eb80c9f7
parentNothing really that wrong with acquiring a disposed reference, for now. (diff)
downloadcore-554be83e0f30d7c47f84195b1677ee1304fe2a34.tar.gz
core-554be83e0f30d7c47f84195b1677ee1304fe2a34.zip
correct debugging assertions.
Change-Id: I2437b4d3c532be6cbb31dccfa9e267498111c183
-rw-r--r--sw/source/core/doc/DocumentDeviceManager.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/sw/source/core/doc/DocumentDeviceManager.cxx b/sw/source/core/doc/DocumentDeviceManager.cxx
index a8ef613150aa..b8b043895171 100644
--- a/sw/source/core/doc/DocumentDeviceManager.cxx
+++ b/sw/source/core/doc/DocumentDeviceManager.cxx
@@ -65,7 +65,7 @@ SfxPrinter* DocumentDeviceManager::getPrinter(/*[in]*/ bool bCreate ) const
void DocumentDeviceManager::setPrinter(/*[in]*/ SfxPrinter *pP,/*[in]*/ bool bDeleteOld,/*[in]*/ bool bCallPrtDataChanged )
{
- assert ( !pP->isDisposed() );
+ assert ( !!pP && !pP->isDisposed() );
if ( pP != mpPrt )
{
if ( bDeleteOld )
@@ -101,7 +101,7 @@ VirtualDevice* DocumentDeviceManager::getVirtualDevice(/*[in]*/ bool bCreate ) c
else
pRet = &CreateVirtualDevice_();
- assert ( !pRet->isDisposed() );
+ assert ( !pRet || !pRet->isDisposed() );
return pRet;
}
@@ -138,7 +138,7 @@ OutputDevice* DocumentDeviceManager::getReferenceDevice(/*[in]*/ bool bCreate )
pRet = getVirtualDevice( bCreate );
}
- assert ( !pRet->isDisposed() );
+ assert ( !pRet || !pRet->isDisposed() );
return pRet;
}