sc/source/core/data/postit.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
New commits: commit 409a7799ba06f3c6b9965f2f35169283a948bc30 Author: Eike Rathke <er...@redhat.com> Date: Tue Mar 14 19:57:04 2017 +0100 no assert for one reference while destroying the Undo document Change-Id: Idf9e0b2600d503ff50cd6269e8d528c0fad12a3e diff --git a/sc/source/core/data/postit.cxx b/sc/source/core/data/postit.cxx index 3addea4..2c96466 100644 --- a/sc/source/core/data/postit.cxx +++ b/sc/source/core/data/postit.cxx @@ -1106,8 +1106,9 @@ void ScPostIt::RemoveCaption() } } // Either the caption object is gone or, because of Undo or clipboard is - // held in at least two instances. - assert(!maNoteData.mxCaption || maNoteData.mxCaption.getRefs() >= 2); + // held in at least two instances, or the Undo document is just destroyed + // which leaves us with one reference. + assert(!maNoteData.mxCaption || maNoteData.mxCaption.getRefs() >= 2 || (mrDoc.IsUndo() && mrDoc.IsInDtorClear())); maNoteData.mxCaption.reset(nullptr); } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits