summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2019-01-14 09:22:17 +0000
committerCaolán McNamara <caolanm@redhat.com>2019-01-14 11:47:35 +0100
commit424a1a8a06eb03d4c84fd63ca1b73abad0324f89 (patch)
tree8b34b0086ed5c230f21af04fee1ee83211222a6c
parent6a70f2a42944918379f3bbefe080a6189bafd6a8 (diff)
ofz#12507 micro opt
Change-Id: I7cdb2e371cb3e209b71659174594bf5bb687f379 Reviewed-on: https://gerrit.libreoffice.org/66284 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--svl/source/items/itempool.cxx4
-rw-r--r--sw/source/core/doc/DocumentStylePoolManager.cxx2
2 files changed, 3 insertions, 3 deletions
diff --git a/svl/source/items/itempool.cxx b/svl/source/items/itempool.cxx
index f0945aaf3b2e..4ac7eb7cd60d 100644
--- a/svl/source/items/itempool.cxx
+++ b/svl/source/items/itempool.cxx
@@ -756,8 +756,8 @@ void SfxItemPool::Remove( const SfxPoolItem& rItem )
SfxPoolItemArray_Impl* pItemArr = pImpl->maPoolItems[nIndex].get();
assert(pItemArr && "removing Item not in Pool");
- SfxPoolItemArray_Impl::PoolItemPtrToIndexMap::const_iterator it;
- it = pItemArr->maPtrToIndex.find(const_cast<SfxPoolItem *>(&rItem));
+ SfxPoolItemArray_Impl::PoolItemPtrToIndexMap::const_iterator it
+ = pItemArr->maPtrToIndex.find(const_cast<SfxPoolItem *>(&rItem));
if (it != pItemArr->maPtrToIndex.end())
{
sal_uInt32 nIdx = it->second;
diff --git a/sw/source/core/doc/DocumentStylePoolManager.cxx b/sw/source/core/doc/DocumentStylePoolManager.cxx
index 7edd055f1e95..19c09209e1bf 100644
--- a/sw/source/core/doc/DocumentStylePoolManager.cxx
+++ b/sw/source/core/doc/DocumentStylePoolManager.cxx
@@ -583,7 +583,7 @@ SwTextFormatColl* DocumentStylePoolManager::GetTextCollFromPool( sal_uInt16 nId,
SwTextFormatColl* pNewColl;
sal_uInt16 nOutLvlBits = 0;
- for( size_t n = 0; n < m_rDoc.GetTextFormatColls()->size(); ++n )
+ for (size_t n = 0, nSize = m_rDoc.GetTextFormatColls()->size(); n < nSize; ++n)
{
if( nId == ( pNewColl = (*m_rDoc.GetTextFormatColls())[ n ] )->GetPoolFormatId() )
{