diff options
-rw-r--r-- | editeng/source/editeng/impedit2.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx index 782402108ea9..db8da11a289e 100644 --- a/editeng/source/editeng/impedit2.cxx +++ b/editeng/source/editeng/impedit2.cxx @@ -3021,9 +3021,10 @@ EditPaM ImpEditEngine::GetPaM( Point aDocPos, sal_Bool bSmart ) nPortion++; pPortion = GetParaPortions().SafeGetObject( nPortion ); } - OSL_ENSURE( pPortion, "No visible paragraph found: GetPaM" ); - aPaM = GetPaM( pPortion, aDocPos, bSmart ); - return aPaM; + assert(pPortion); //No visible paragraph found: GetPaM + if (!pPortion) + return aPaM; + return GetPaM(pPortion, aDocPos, bSmart); } } |