[Libreoffice-commits] .: sc/source

David Tardon dtardon at kemper.freedesktop.org
Tue Mar 22 06:12:15 PDT 2011


 sc/source/core/data/segmenttree.cxx |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 6fbf4caf7385d988559701d14ceed7925b76997d
Author: David Tardon <dtardon at redhat.com>
Date:   Tue Mar 22 14:11:12 2011 +0100

    beware of invalidated iterator

diff --git a/sc/source/core/data/segmenttree.cxx b/sc/source/core/data/segmenttree.cxx
index d7d1153..08c3e3c 100644
--- a/sc/source/core/data/segmenttree.cxx
+++ b/sc/source/core/data/segmenttree.cxx
@@ -204,12 +204,14 @@ template<typename _ValueType, typename _ExtValueType>
 void ScFlatSegmentsImpl<_ValueType, _ExtValueType>::removeSegment(SCCOLROW nPos1, SCCOLROW nPos2)
 {
     maSegments.shift_left(nPos1, nPos2);
+    maItr = maSegments.begin();
 }
 
 template<typename _ValueType, typename _ExtValueType>
 void ScFlatSegmentsImpl<_ValueType, _ExtValueType>::insertSegment(SCCOLROW nPos, SCCOLROW nSize, bool bSkipStartBoundary)
 {
     maSegments.shift_right(nPos, nSize, bSkipStartBoundary);
+    maItr = maSegments.begin();
 }
 
 template<typename _ValueType, typename _ExtValueType>


More information about the Libreoffice-commits mailing list