[Libreoffice-commits] .: 4 commits - svtools/source toolkit/source vcl/source
Caolán McNamara
caolan at kemper.freedesktop.org
Sun Nov 28 05:04:48 PST 2010
svtools/source/filter.vcl/ixbm/xbmread.cxx | 2 +-
svtools/source/uno/unoimap.cxx | 10 +++++-----
toolkit/source/helper/unopropertyarrayhelper.cxx | 2 +-
vcl/source/glyphs/gcach_ftyp.cxx | 1 +
4 files changed, 8 insertions(+), 7 deletions(-)
New commits:
commit e143ee99b6871c864e409d31ac7b025f77b3a298
Author: Caolán McNamara <caolanm at redhat.com>
Date: Sun Nov 28 12:29:04 2010 +0000
cppcheck: use prefix variant
diff --git a/svtools/source/uno/unoimap.cxx b/svtools/source/uno/unoimap.cxx
index 3a61bc6..236da55 100644
--- a/svtools/source/uno/unoimap.cxx
+++ b/svtools/source/uno/unoimap.cxx
@@ -660,7 +660,7 @@ void SAL_CALL SvUnoImageMap::insertByIndex( sal_Int32 Index, const Any& Element
{
std::list< SvUnoImageMapObject* >::iterator aIter = maObjectList.begin();
for( sal_Int32 n = 0; n < Index; n++ )
- aIter++;
+ ++aIter;
maObjectList.insert( aIter, pObject );
}
@@ -681,7 +681,7 @@ void SAL_CALL SvUnoImageMap::removeByIndex( sal_Int32 Index ) throw(IndexOutOfBo
{
std::list< SvUnoImageMapObject* >::iterator aIter = maObjectList.begin();
for( sal_Int32 n = 0; n < Index; n++ )
- aIter++;
+ ++aIter;
(*aIter)->release();
maObjectList.erase( aIter );
@@ -698,7 +698,7 @@ void SAL_CALL SvUnoImageMap::replaceByIndex( sal_Int32 Index, const Any& Element
std::list< SvUnoImageMapObject* >::iterator aIter = maObjectList.begin();
for( sal_Int32 n = 0; n < Index; n++ )
- aIter++;
+ ++aIter;
(*aIter)->release();
*aIter = pObject;
@@ -719,7 +719,7 @@ Any SAL_CALL SvUnoImageMap::getByIndex( sal_Int32 Index ) throw(IndexOutOfBounds
std::list< SvUnoImageMapObject* >::iterator aIter = maObjectList.begin();
for( sal_Int32 n = 0; n < Index; n++ )
- aIter++;
+ ++aIter;
Reference< XPropertySet > xObj( *aIter );
return makeAny( xObj );
@@ -778,7 +778,7 @@ sal_Bool SvUnoImageMap::fillImageMap( ImageMap& rMap ) const
rMap.InsertIMapObject( *pNewMapObject );
delete pNewMapObject;
- aIter++;
+ ++aIter;
}
return sal_True;
commit fa4a93076913ec7c0d1a376691c3e0d11788946c
Author: Caolán McNamara <caolanm at redhat.com>
Date: Sun Nov 28 12:16:41 2010 +0000
cppcheck: can use prefix variant
diff --git a/toolkit/source/helper/unopropertyarrayhelper.cxx b/toolkit/source/helper/unopropertyarrayhelper.cxx
index 0902fdd..3f8c814 100644
--- a/toolkit/source/helper/unopropertyarrayhelper.cxx
+++ b/toolkit/source/helper/unopropertyarrayhelper.cxx
@@ -47,7 +47,7 @@ UnoPropertyArrayHelper::UnoPropertyArrayHelper( const ::com::sun::star::uno::Seq
UnoPropertyArrayHelper::UnoPropertyArrayHelper( const std::list< sal_uInt16 > &rIDs )
{
std::list< sal_uInt16 >::const_iterator iter;
- for( iter = rIDs.begin(); iter != rIDs.end(); iter++)
+ for( iter = rIDs.begin(); iter != rIDs.end(); ++iter)
maIDs.Insert( *iter, (void*)1L);
}
commit b2f65a22e91280bf662c6a0259dbe5c9e56aa77c
Author: Caolán McNamara <caolanm at redhat.com>
Date: Sun Nov 28 12:11:30 2010 +0000
cppcheck: uninit member variable
diff --git a/vcl/source/glyphs/gcach_ftyp.cxx b/vcl/source/glyphs/gcach_ftyp.cxx
index 543df46..729b2e9 100644
--- a/vcl/source/glyphs/gcach_ftyp.cxx
+++ b/vcl/source/glyphs/gcach_ftyp.cxx
@@ -2090,6 +2090,7 @@ PolyArgs::PolyArgs( PolyPolygon& rPolyPoly, USHORT nMaxPoints )
mnMaxPoints(nMaxPoints),
mnPoints(0),
mnPoly(0),
+ mnHeight(0),
bHasOffline(false)
{
mpPointAry = new Point[ mnMaxPoints ];
commit 7678168bda17a58c747942cbff8db2d4c03aeb18
Author: Caolán McNamara <caolanm at redhat.com>
Date: Sun Nov 28 12:08:46 2010 +0000
cppcheck: reduce the scope of this variable
diff --git a/svtools/source/filter.vcl/ixbm/xbmread.cxx b/svtools/source/filter.vcl/ixbm/xbmread.cxx
index 01bb7c4..52980f0 100644
--- a/svtools/source/filter.vcl/ixbm/xbmread.cxx
+++ b/svtools/source/filter.vcl/ixbm/xbmread.cxx
@@ -287,7 +287,6 @@ ReadState XBMReader::ReadXBM( Graphic& rGraphic )
if ( rIStm.GetError() != ERRCODE_IO_PENDING )
{
ByteString aLine;
- int nValue;
rIStm.Seek( nLastPos );
bStatus = FALSE;
@@ -295,6 +294,7 @@ ReadState XBMReader::ReadXBM( Graphic& rGraphic )
if ( bStatus )
{
+ int nValue;
if ( ( nValue = (int) ParseDefine( aLine.GetBuffer() ) ) > 0 )
{
nWidth = nValue;
More information about the Libreoffice-commits
mailing list