summaryrefslogtreecommitdiff
path: root/sw/source/core/undo/untbl.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/undo/untbl.cxx')
-rw-r--r--sw/source/core/undo/untbl.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/sw/source/core/undo/untbl.cxx b/sw/source/core/undo/untbl.cxx
index 11dbb4b7eeaa..e3a6af5d7a6a 100644
--- a/sw/source/core/undo/untbl.cxx
+++ b/sw/source/core/undo/untbl.cxx
@@ -1757,3 +1757,7 @@ void SwUndoTblNdsChg::UndoImpl(::sw::UndoRedoContext & rContext)
else
+ { // first disconnect box from node, otherwise ~SwTableBox would
+ // access pBox->pSttNd, deleted by DeleteSection
+ pBox->RemoveFromTable();
rDoc.DeleteSection( rDoc.GetNodes()[ nIdx ] );
+ }
aDelBoxes.insert( aDelBoxes.end(), pBox );
@@ -1773,2 +1777,3 @@ void SwUndoTblNdsChg::UndoImpl(::sw::UndoRedoContext & rContext)
pPCD->DeleteBox( &pTblNd->GetTable(), *pBox );
+ pBox->RemoveFromTable(); // ~SwTableBox would access pBox->pSttNd
aDelBoxes.insert( aDelBoxes.end(), pBox );