sc/source/core/data/table2.cxx | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-)
New commits: commit 39e7aefe5d3645f08867c84e1c5dd08c7209a439 Author: Markus Mohrhard <markus.mohrh...@googlemail.com> Date: Fri Oct 12 16:46:55 2012 +0200 don't insert notes from deleted cells, fdo#55885 Change-Id: I036f0531dc2290c5eb480258bc70ec13b810e6bc Signed-off-by: Kohei Yoshida <kohei.yosh...@gmail.com> Signed-off-by: Eike Rathke <er...@redhat.com> Signed-off-by: Noel Power <nopo...@novell.com> diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index 4230cbd..cd193c1 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -267,8 +267,13 @@ void ScTable::DeleteRow( SCCOL nStartCol, SCCOL nEndCol, SCROW nStartRow, SCSIZE if (nRow >= nStartRow) { - aNotes.insert(nCol, nRow - nSize, pPostIt); - maNotes.ReleaseNote(nCol, nRow); + if(nRow - nStartRow > static_cast<SCROW>(nSize)) + { + aNotes.insert(nCol, nRow - nSize, pPostIt); + maNotes.ReleaseNote(nCol, nRow); + } + else + maNotes.erase(nCol, nRow); } } @@ -486,8 +491,13 @@ void ScTable::DeleteCol( SCCOL nStartCol, SCROW nStartRow, SCROW nEndRow, SCSIZE if (nCol >= nStartCol) { - aNotes.insert(nCol - nSize, nRow, pPostIt); - maNotes.ReleaseNote(nCol, nRow); + if(nCol - nStartCol > static_cast<SCCOL>(nSize)) + { + aNotes.insert(nCol - nSize, nRow, pPostIt); + maNotes.ReleaseNote(nCol, nRow); + } + else + maNotes.erase(nCol, nRow); } } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits