summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMichael Stahl <michael.stahl@allotropia.de>2022-07-15 20:55:35 +0200
committerMichael Stahl <michael.stahl@allotropia.de>2022-07-18 10:58:00 +0200
commitde49e1c55dc10ce1b59345af5cc49fde3adf65b7 (patch)
tree213f8802a1c7faf5915645edeeef16056b75efcb /sw
parent5dc4274eb5ccf3c2cc29676280b70dfc5d5a43b3 (diff)
tdf#149548 sw: don't rely on binary search in SplitRedline()
The problem is that for this bugdoc overlapping redlines are created by writerfilter, and so this one survives the split in SwDoc::TextToTable() when creating a cell on node 146 to 149: $125 = (SwRangeRedline) { <SwPaM> = SwPaM = { point = SwPosition (node 155, offset 156), mark = SwPosition (node 146, offset 0) }, It's not found in GetRedline(), as that relies on the redlines never overlapping, so isn't split at end of 149. Then when copying to the clipboard, all redlines are deleted and this deletes cell start and end nodes, while the cell's SwTableBox is still referenced elsewhere. (reportedly somehow a regression from commit c4cf85766453982f1aa94a7f2cb22af19ed100be) Change-Id: I6466e6777cd83c7625381f7049f30c8a2f487af1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137110 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/doc/DocumentRedlineManager.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sw/source/core/doc/DocumentRedlineManager.cxx b/sw/source/core/doc/DocumentRedlineManager.cxx
index 9e3d79c14146..fb7580a4862f 100644
--- a/sw/source/core/doc/DocumentRedlineManager.cxx
+++ b/sw/source/core/doc/DocumentRedlineManager.cxx
@@ -2490,7 +2490,7 @@ bool DocumentRedlineManager::SplitRedline( const SwPaM& rRange )
SwRedlineTable::size_type n = 0;
const SwPosition* pStt = rRange.Start();
const SwPosition* pEnd = rRange.End();
- GetRedline( *pStt, &n );
+ //FIXME overlapping problem GetRedline( *pStt, &n );
for ( ; n < maRedlineTable.size(); ++n)
{
SwRangeRedline * pRedline = maRedlineTable[ n ];