From 9c6ca789ef80eefff1875b7c804c343ff1668ce0 Mon Sep 17 00:00:00 2001 From: Lionel Elie Mamane Date: Thu, 9 Feb 2012 13:06:27 +0100 Subject: reorganise code for better readability No behaviour change intended. However, if behaviour changed, probably the *old* behaviour is buggy, not new one. --- dbaccess/source/core/api/RowSetCache.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'dbaccess') diff --git a/dbaccess/source/core/api/RowSetCache.cxx b/dbaccess/source/core/api/RowSetCache.cxx index 08e1a8bfcc4f..6a853e6399a3 100644 --- a/dbaccess/source/core/api/RowSetCache.cxx +++ b/dbaccess/source/core/api/RowSetCache.cxx @@ -1074,17 +1074,17 @@ sal_Bool ORowSetCache::moveWindow() { aIter = m_pMatrix->begin(); - nPos = m_nStartPos; - bCheck = m_pCacheSet->absolute_checked(m_nStartPos,sal_False); - for(; !aIter->is() && bCheck;++aIter) + nPos = m_nStartPos + 1; + bCheck = m_pCacheSet->absolute_checked(nPos, sal_False); + for(; !aIter->is() && bCheck;++aIter, ++nPos) { OSL_ENSURE(aIter != m_pMatrix->end(),"Invalid iterator"); - bCheck = m_pCacheSet->next(); if ( bCheck ) // resultset stands on right position { *aIter = new ORowSetValueVector(m_xMetaData->getColumnCount()); - m_pCacheSet->fillValueRow(*aIter,++nPos); + m_pCacheSet->fillValueRow(*aIter, nPos); } + bCheck = m_pCacheSet->next(); } } } -- cgit