sw/source/filter/xml/swxml.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
New commits: commit eae887b628fde6b73d354b4788c8303db9c36aac Author: Michael Stahl <michael.st...@allotropia.de> AuthorDate: Tue Jan 18 14:11:34 2022 +0100 Commit: Thorsten Behrens <thorsten.behr...@allotropia.de> CommitDate: Mon Jan 24 10:11:43 2022 +0100 sw_fieldmarkhide: disable layout cache if there are fieldmarks ... similar to the "ShowChanges" check that is already done. This prevents a crash in SwLayoutCache::CompareLayout() on fdo38619-2.ott Change-Id: I1a90c45f041ae18beacd3fbd4dcbdae5ba86c317 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128556 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.st...@allotropia.de> (cherry picked from commit 3170fba5dff3ea5cc67ea94f51a0dd5458f01edd) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128536 Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org> Signed-off-by: Xisco Fauli <xiscofa...@libreoffice.org> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128633 Reviewed-by: Adolfo Jayme Barrientos <fit...@ubuntu.com> Reviewed-by: Thorsten Behrens <thorsten.behr...@allotropia.de> Tested-by: Thorsten Behrens <thorsten.behr...@allotropia.de> diff --git a/sw/source/filter/xml/swxml.cxx b/sw/source/filter/xml/swxml.cxx index 8b4ae9b031f3..5b74af04e794 100644 --- a/sw/source/filter/xml/swxml.cxx +++ b/sw/source/filter/xml/swxml.cxx @@ -845,7 +845,10 @@ ErrCode XMLReader::Read( SwDoc &rDoc, const OUString& rBaseURL, SwPaM &rPaM, con if( !IsOrganizerMode() && !IsBlockMode() && !m_bInsertMode && !m_aOption.IsFormatsOnly() && // sw_redlinehide: disable layout cache for now - *o3tl::doAccess<bool>(xInfoSet->getPropertyValue(sShowChanges))) + *o3tl::doAccess<bool>(xInfoSet->getPropertyValue(sShowChanges)) && + // sw_fieldmarkhide: also disable if there is a fieldmark + rDoc.getIDocumentMarkAccess()->getFieldmarksBegin() + == rDoc.getIDocumentMarkAccess()->getFieldmarksEnd()) { try {