tdf#155685 sw: fix another ExtendedSelectAll Redo crash w table at end
This can be reproduced with a table containing in the last cell a
paragraph followed by a table, then ExtendedSelectAll in the cell and
delete.
On Redo of the SwUndoDelete:
warn:legacy.osl:326138:326138:sw/source/core/frmedt/tblsel.cxx:1775: MakeSelUnions with pStart or pEnd not in CellFrame
In function:
const_reference std::vector<SwTableBox *>::operator[](size_type) const
[_Tp = SwTableBox *, _Allocator = std::allocator<SwTableBox *>]
Error: attempt to subscript container with out-of-bounds index 0, but
container only holds 0 elements.
The problem is that DelTable() calls PaMCorrAbs() with a target that is
outside of the outer table, so the SwEditShell::DeleteSel() rPam has one
end in the last table cell and other end outside the table.
Change-Id: Ia2764a4c99ba12102957153e005284a44be04fd0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153114
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
(cherry picked from commit
4ef548a672658ab164e45e45ebd1b9f0b9282019)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153088