From e4ffcf3225ab4ec38c704f4ba0d1f987e4368af5 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Sat, 1 Oct 2022 16:49:11 +0100 Subject: crashtesting: assert on ooo8886-16.sxw seems a regression from: commit d7234feac18dbb94fef310e8c241428426b27717 (HEAD, refs/bisect/bad) Date: Thu Aug 25 18:45:33 2022 +0200 use more SwPosition::Assign Change-Id: I80602b2cc01b28986b04a97fce5c51673e6fe8a3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140848 Tested-by: Jenkins Reviewed-by: Noel Grandin --- sw/source/core/doc/doccorr.cxx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sw/source/core/doc/doccorr.cxx b/sw/source/core/doc/doccorr.cxx index a98fedb58708..596634bb5e1f 100644 --- a/sw/source/core/doc/doccorr.cxx +++ b/sw/source/core/doc/doccorr.cxx @@ -77,9 +77,8 @@ namespace SwPosition & rPos = pPam->GetBound(bool(nb)); if(&rPos.GetNode() == pOldNode) { - rPos.Assign( rNewPos.GetNode() ); - if(rNewPos.GetNode().GetContentNode()) - rPos.AdjustContent(nCntIdx); + rPos.Assign(rNewPos.GetNode(), SwNodeOffset(0), + nCntIdx + rPos.GetContentIndex()); } } } -- cgit