Copy-and-paste of cells with formulas can corrupt the receiving spreadsheet, causing later crashes, if the formulas refer to Named Ranges and/or macros which do not exist in the receiving spreadsheet. Please load the attached demo and attempt to delete row 3 LO crashes with vector::_M_range_check. The problem seems to be triggered by the cells with broken formulas, but I can't determine exactly what part of the formulas causes LO to go addled. The formulas referenced Named Ranges which don't exist in the receiving spreadsheet; they also had Conditional Formats applied in the source spreadsheet. Sorry to not be specific, but the demo is very small and simple and hopefully it will be easy to track down what is wrong. This might be a REGRESSION, as the demo doesn't crash in 4.2.0.3 (although it might be just luck).
Created attachment 95765 [details] Mrangecheck.ods - delete row 3 to see the crash
Created attachment 95766 [details] MrangecheckNoMacros.ods - delete row 3 to see crash
I am marking this a duplicate of bug 76008 "out_of_range exception from: copy formula, paste, undo". The resemblances between the two bugs are: (a) Same error messages (b) The user was deleting a formula. The differences between them are: (c) Explicit row deletion vs. undoing a paste into one cell. (d) The formula involved in bug 76008 does not, so far as I know, have an error. *** This bug has been marked as a duplicate of bug 76008 ***
Change bug duplicate to bug 76470, because it is more relevant and already assigned. *** This bug has been marked as a duplicate of bug 76470 ***
We have evidence for this bug being a duplicate of 76470. The crash has gone away between commit 924635e (fetched 2014-03-22 01:18 UTC) and commit 8931ab3 (fetched 2014-03-23 02:37 UTC). That range includes commit c78d1bb "fdo#76470: Avoid joining new formula cells individually.". @Jim, When you see the problem fixed, it would be good to advance the bug status to VERIFIED.
Verified that the demo no longer crashes on 4.3alpha (built 2014-03-25_10:00:54). Thanks very much!
Also now verified using 4.2.4.0.0+ built 2014-03-25_11:34:44