[Libreoffice-commits] core.git: Branch 'libreoffice-6-1' - editeng/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Sat Aug 11 09:49:41 UTC 2018
editeng/source/editeng/impedit2.cxx | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit 22b9bee790a6b63b11369a7ae7257ceaef9d8585
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Fri Aug 10 16:43:11 2018 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Sat Aug 11 11:49:21 2018 +0200
tdf#119169 impress, crash when editing bulleted list
regression from
commit e278df1a14c5cb5dbb7add5d6ed5dd52da131e92
tdf#108608 Draw file unresponsive on large text pasted into textbox
Somewhere up in the accessibility code it has a stale paragraph index.
Judging up other code in this class, that is fairly common, so just add
similar safety checks.
The old code (pre-regression) only worked because it iterated over all
paragraphs, and it just ignored the paragraph index.
Change-Id: I51c573b95f976fa87228e4f7e9f33bd6ea0dc3c8
Reviewed-on: https://gerrit.libreoffice.org/58836
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
(cherry picked from commit 36a2af004e1a7b17a71d8327c7ae2b6091ab0ffa)
Reviewed-on: https://gerrit.libreoffice.org/58855
diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx
index 4bd83aa6e644..7e8fb846136a 100644
--- a/editeng/source/editeng/impedit2.cxx
+++ b/editeng/source/editeng/impedit2.cxx
@@ -3110,8 +3110,9 @@ sal_uInt32 ImpEditEngine::CalcParaWidth( sal_Int32 nPara, bool bIgnoreExtraSpace
// Over all the paragraphs ...
+ OSL_ENSURE( 0 <= nPara && nPara < GetParaPortions().Count(), "CalcParaWidth: Out of range" );
ParaPortion* pPortion = GetParaPortions()[nPara];
- if ( pPortion->IsVisible() )
+ if ( pPortion && pPortion->IsVisible() )
{
const SvxLRSpaceItem& rLRItem = GetLRSpaceItem( pPortion->GetNode() );
sal_Int32 nSpaceBeforeAndMinLabelWidth = GetSpaceBeforeAndMinLabelWidth( pPortion->GetNode() );
More information about the Libreoffice-commits
mailing list