From a6e7509e1b7f20f7bd266d9c4d7bd0e5b1c72907 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= Date: Thu, 31 Dec 2020 10:13:09 +0000 Subject: loplugin:loopvartoosmall fix build MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I2f9aa75f8e4f0577261fb84a9629c183d3a72b70 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108534 Tested-by: Caolán McNamara Reviewed-by: Caolán McNamara --- xmloff/source/style/xmlexppr.cxx | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'xmloff') diff --git a/xmloff/source/style/xmlexppr.cxx b/xmloff/source/style/xmlexppr.cxx index a9cc2962155e..0e35f8b1948b 100644 --- a/xmloff/source/style/xmlexppr.cxx +++ b/xmloff/source/style/xmlexppr.cxx @@ -267,7 +267,7 @@ void FilterPropertiesInfo_Impl::FillPropertyStateArray( const beans::GetDirectPropertyTolerantResult *pResults = aResults.getConstArray(); FilterPropertyInfoList_Impl::iterator aPropIter(aPropInfos.begin()); XMLPropertyState aNewProperty( -1 ); - sal_uInt32 i = 0; + size_t i = 0; while (nResultCount > 0 && i < aPropInfos.size()) { if (pResults->Name == aPropIter->GetApiName()) @@ -332,9 +332,8 @@ void FilterPropertiesInfo_Impl::FillPropertyStateArray( { // step 1: get value count sal_uInt32 nValueCount = 0; - sal_uInt32 i; - for( i = 0; i < aPropInfos.size(); ++i, ++pStates ) + for (size_t i = 0; i < aPropInfos.size(); ++i, ++pStates) { if( *pStates == PropertyState_DIRECT_VALUE ) nValueCount++; @@ -353,7 +352,7 @@ void FilterPropertiesInfo_Impl::FillPropertyStateArray( OSL_ENSURE(aItr != aPropInfos.end(),"Invalid iterator!"); pStates = aStates.getConstArray(); - i = 0; + sal_uInt32 i = 0; while( i < nValueCount ) { if( *pStates == PropertyState_DIRECT_VALUE ) @@ -395,7 +394,7 @@ void FilterPropertiesInfo_Impl::FillPropertyStateArray( const Any *pValues = aValues.getConstArray(); FilterPropertyInfoList_Impl::iterator aItr = aPropInfos.begin(); - for(sal_uInt32 i = 0; i < aPropInfos.size(); ++i) + for (size_t i = 0; i < aPropInfos.size(); ++i) { // The value is stored in the PropertySet itself, add to list. XMLPropertyState aNewProperty( -1 ); @@ -413,7 +412,7 @@ void FilterPropertiesInfo_Impl::FillPropertyStateArray( else { FilterPropertyInfoList_Impl::iterator aItr = aPropInfos.begin(); - for(sal_uInt32 i = 0; i < aPropInfos.size(); ++i) + for (size_t i = 0; i < aPropInfos.size(); ++i) { bool bDirectValue = !pStates || *pStates == PropertyState_DIRECT_VALUE; -- cgit v1.2.1