[Libreoffice-commits] core.git: sc/source
László Németh
laszlo.nemeth at collabora.com
Wed Feb 18 07:24:56 PST 2015
sc/source/core/data/dociter.cxx | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
New commits:
commit 8e9540d3d4909c6dd45c9efa294f565d9735a0d9
Author: László Németh <laszlo.nemeth at collabora.com>
Date: Wed Feb 18 16:22:56 2015 +0100
tdf#89436 ScHorizontalAttrIterator - fix indices
Change-Id: I800270cc4b1a812834be57b9eb332b4b299c0fe1
diff --git a/sc/source/core/data/dociter.cxx b/sc/source/core/data/dociter.cxx
index 3b3b2b1..cf8cbe2 100644
--- a/sc/source/core/data/dociter.cxx
+++ b/sc/source/core/data/dociter.cxx
@@ -2301,13 +2301,13 @@ const ScPatternAttr* ScHorizontalAttrIterator::GetNext( SCCOL& rCol1, SCCOL& rCo
rRow = nRow;
rCol1 = nCol;
if ( bRepeatedRow )
- nCol = pPrevColEnd[nCol];
+ nCol = pPrevColEnd[nCol-nStartCol]; // use the result stored before
else
{
while ( nCol < nEndCol && ( ppPatterns[nCol+1-nStartCol] == pPat) )
++nCol;
// store the result to avoid the previous very expensive comparisons
- pPrevColEnd[rCol1] = nCol;
+ pPrevColEnd[rCol1-nStartCol] = nCol;
}
rCol2 = nCol;
++nCol; // Count up for next call
More information about the Libreoffice-commits
mailing list