User: rt Date: 05/09/05 01:57:57 Modified: /dba/dbaccess/source/core/api/ RowSetCache.cxx
Log: INTEGRATION: CWS hr18 (1.75.88); FILE MERGED 2005/08/10 16:43:29 hr 1.75.88.1: #i51878#,#i53108#: cleanup STL iterator usage File Changes: Directory: /dba/dbaccess/source/core/api/ ========================================= File [changed]: RowSetCache.cxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/core/api/RowSetCache.cxx?r1=1.75&r2=1.76 Delta lines: +7 -7 ------------------- --- RowSetCache.cxx 18 Mar 2005 10:05:15 -0000 1.75 +++ RowSetCache.cxx 5 Sep 2005 08:57:54 -0000 1.76 @@ -431,7 +431,7 @@ for(;aCacheIter != m_aCacheIterators.end();++aCacheIter) { aCacheIterToChange[aCacheIter->first] = sal_False; - if(!aCacheIter->second.aIterator) + if ( aCacheIter->second.aIterator == m_pMatrix->end() ) continue; if(aCacheIter->second.aIterator != m_aInsertRow && !m_bInserted && !m_bModified) { @@ -979,14 +979,14 @@ ORowSetCacheMap::iterator aCacheIter = m_aCacheIterators.begin(); for(;aCacheIter != m_aCacheIterators.end();++aCacheIter) { - if ( aCacheIter->second.aIterator + if ( aCacheIter->second.aIterator != m_pMatrix->end() && aCacheIter->second.aIterator != m_aInsertRow && !m_bInserted && !m_bModified ) { sal_Int16 nDist = (aCacheIter->second.aIterator - m_pMatrix->begin()); if ( nDist >= nNewDist ) { - aCacheIter->second.aIterator = NULL; + aCacheIter->second.aIterator = m_pMatrix->end(); } else { @@ -1417,11 +1417,11 @@ ORowSetCacheMap::iterator aCacheIter = m_aCacheIterators.begin(); for(;aCacheIter != m_aCacheIterators.end();++aCacheIter) { - if(aCacheIter->second.aIterator) + if ( aCacheIter->second.aIterator != m_pMatrix->end() ) { ORowSetMatrix::iterator aOldIter = aCacheIter->second.aIterator; if(aOldIter == m_aInsertRow) - aCacheIter->second.aIterator = NULL; + aCacheIter->second.aIterator = m_pMatrix->end(); } } } @@ -1596,12 +1596,12 @@ ORowSetCacheMap::iterator aCacheIter = m_aCacheIterators.begin(); for(;aCacheIter != m_aCacheIterators.end();++aCacheIter) { - if(aCacheIter->second.aIterator && aCacheIter->second.aIterator != m_aInsertRow && !m_bInserted && !m_bModified) + if ( aCacheIter->second.aIterator != m_pMatrix->end() && aCacheIter->second.aIterator != m_aInsertRow && !m_bInserted && !m_bModified) { sal_Int16 nDist = (aCacheIter->second.aIterator - m_pMatrix->begin()); if(nDist < _nDist) { - aCacheIter->second.aIterator = NULL; + aCacheIter->second.aIterator = m_pMatrix->end(); } else { --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
