diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-07-03 08:51:19 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-07-03 12:49:38 +0100 |
commit | 4228f08d6084d8563b70a26a6398fb0caf017f99 (patch) | |
tree | 2f91cb13231f0de1e514dd545e0910b830589fb4 /starmath | |
parent | 6fe1e3af0e812d99e63677d9ead056357b37ecf7 (diff) |
use assert when followed by deref
Change-Id: I8405e4d8f9fa1de3ef6ee474321b4ac2b4ce1624
Diffstat (limited to 'starmath')
-rw-r--r-- | starmath/source/document.cxx | 2 | ||||
-rw-r--r-- | starmath/source/view.cxx | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/starmath/source/document.cxx b/starmath/source/document.cxx index 4009d6a8d5fd..738aac2bbb07 100644 --- a/starmath/source/document.cxx +++ b/starmath/source/document.cxx @@ -403,7 +403,7 @@ SfxItemPool& SmDocShell::GetEditEngineItemPool() { if (!pEditEngineItemPool) GetEditEngine(); - OSL_ENSURE( pEditEngineItemPool, "EditEngineItemPool missing" ); + assert(pEditEngineItemPool && "EditEngineItemPool missing"); return *pEditEngineItemPool; } diff --git a/starmath/source/view.cxx b/starmath/source/view.cxx index e60f22df460d..95a6a65686fb 100644 --- a/starmath/source/view.cxx +++ b/starmath/source/view.cxx @@ -2007,8 +2007,8 @@ void SmViewShell::Activate( bool bIsMDIActivate ) IMPL_LINK( SmViewShell, DialogClosedHdl, sfx2::FileDialogHelper*, _pFileDlg ) { - SAL_WARN_IF( !_pFileDlg, "starmath", "SmViewShell::DialogClosedHdl(): no file dialog" ); - SAL_WARN_IF( !pImpl->pDocInserter, "starmath", "ScDocShell::DialogClosedHdl(): no document inserter" ); + assert(_pFileDlg && "SmViewShell::DialogClosedHdl(): no file dialog"); + assert(pImpl->pDocInserter && "ScDocShell::DialogClosedHdl(): no document inserter"); if ( ERRCODE_NONE == _pFileDlg->GetError() ) { |