summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2012-05-20 15:25:00 +0200
committerJulien Nabet <serval2412@yahoo.fr>2012-05-20 15:25:37 +0200
commitc53812a1b7c45b1b5a4a341b178c40602c7dcbf7 (patch)
treec9d6a029aa5f4e6081be0aadb2ee2a11e68aa285 /vcl
parentb8c046acfc235cbfb09d598b502a66922045cabc (diff)
Some cppcheck cleaning
Change-Id: Ic30cdeffabec1eb1a6c153ac450a3d28064ef534
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/gdi/gdimtf.cxx2
-rw-r--r--vcl/source/gdi/pdfwriter_impl.cxx2
2 files changed, 2 insertions, 2 deletions
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx
index 93be21a86829..da073f65a0aa 100644
--- a/vcl/source/gdi/gdimtf.cxx
+++ b/vcl/source/gdi/gdimtf.cxx
@@ -392,7 +392,6 @@ void GDIMetaFile::Play( OutputDevice* pOut, size_t nPos )
{
MetaAction* pAction = GetCurAction();
const size_t nObjCount = aList.size();
- size_t i = 0;
size_t nSyncCount = ( pOut->GetOutDevType() == OUTDEV_WINDOW ) ? 0x000000ff : 0xffffffff;
if( nPos > nObjCount )
@@ -409,6 +408,7 @@ void GDIMetaFile::Play( OutputDevice* pOut, size_t nPos )
OSL_TRACE("GDIMetaFile::Play on device of size: %d x %d", pOut->GetOutputSizePixel().Width(), pOut->GetOutputSizePixel().Height());
if( !ImplPlayWithRenderer( pOut, Point(0,0), pOut->GetOutputSizePixel() ) ) {
+ size_t i = 0;
for( size_t nCurPos = nCurrentActionElement; nCurPos < nPos; nCurPos++ )
{
if( !Hook() )
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx
index 953dc65312ab..797159edb436 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -3297,7 +3297,7 @@ std::map< sal_Int32, sal_Int32 > PDFWriterImpl::emitEmbeddedFont( const ImplFont
std::list< int > aSections;
std::list< int >::const_iterator it;
int nIndex = 0;
- while( pFontData[nIndex] == 0x80 && nIndex < nFontLen-1 )
+ while( (nIndex < nFontLen-1) && pFontData[nIndex] == 0x80 )
{
aSections.push_back( nIndex );
if( pFontData[nIndex+1] == 0x03 )