sw/source/core/doc/DocumentContentOperationsManager.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
New commits: commit dc3a473ef127bf804ffe23e5db869db6d61bd7a9 Author: Michael Stahl <michael.st...@allotropia.de> AuthorDate: Tue Dec 14 19:34:36 2021 +0100 Commit: Michael Stahl <michael.st...@allotropia.de> CommitDate: Fri Dec 17 11:24:55 2021 +0100 tdf#141175 sw_redlinehide: fix crash in lcl_DeleteRedlines() The GetNext() returns itself if it's alone in the Ring. (regression from 27aa4b16bf704d0246595750daf57b57ff2577b3) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126844 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.st...@allotropia.de> (cherry picked from commit 19f2054c6063177d08c818c5b7eeba7ab9178249) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126824 Reviewed-by: Thorsten Behrens <thorsten.behr...@allotropia.de> (cherry picked from commit 7b672a6d89581885c305068a714a72b5352de12f) Change-Id: Idf92ce5362c4a4acf1582f463fe7bafc8553b400 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126954 Tested-by: Michael Stahl <michael.st...@allotropia.de> Reviewed-by: Michael Stahl <michael.st...@allotropia.de> diff --git a/sw/source/core/doc/DocumentContentOperationsManager.cxx b/sw/source/core/doc/DocumentContentOperationsManager.cxx index c3e5298c81da..758c990e927e 100644 --- a/sw/source/core/doc/DocumentContentOperationsManager.cxx +++ b/sw/source/core/doc/DocumentContentOperationsManager.cxx @@ -387,7 +387,8 @@ namespace *pDelPam->GetPoint(), nDelCount ); } - if (pDelPam->GetNext() && *pDelPam->GetNext()->End() == *pDelPam->Start()) + if (pDelPam->GetNext() != pDelPam.get() + && *pDelPam->GetNext()->End() == *pDelPam->Start()) { *pDelPam->GetNext()->End() = *pDelPam->End(); pDelPam.reset(pDelPam->GetNext());