[Libreoffice-commits] .: 2 commits - filter/source

Noel Power noelp at kemper.freedesktop.org
Mon Mar 28 04:17:49 PDT 2011


 filter/source/svg/svgwriter.cxx |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 2a791e420b7a402dc43b3cc17b5945066a8b3eb3
Merge: 431ee37... 201845d...
Author: Noel Power <noel.power at novell.com>
Date:   Mon Mar 28 12:16:48 2011 +0100

    Merge branch 'master' of ssh://git.freedesktop.org/git/libreoffice/filters

commit 431ee3745f398522b36b5ba6db2696b91ef5a6ab
Author: Kayo Hamid <kayo.hamid at gekkolinux.com.br>
Date:   Mon Mar 28 12:14:02 2011 +0100

    removes some variableScope cppcheck warnings

diff --git a/filter/source/svg/svgwriter.cxx b/filter/source/svg/svgwriter.cxx
index 052a930..c0cd48f 100644
--- a/filter/source/svg/svgwriter.cxx
+++ b/filter/source/svg/svgwriter.cxx
@@ -489,7 +489,7 @@ NMSP_RTL::OUString	SVGActionWriter::GetPathString( const PolyPolygon& rPolyPoly,
     for( long i = 0, nCount = rPolyPoly.Count(); i < nCount; i++ )
     {
         const Polygon&	rPoly = rPolyPoly[ (sal_uInt16) i ];
-        sal_uInt16			n = 1, nSize = rPoly.GetSize();
+        sal_uInt16			nSize = rPoly.GetSize();
 
         if( nSize > 1 )
         {
@@ -498,6 +498,7 @@ NMSP_RTL::OUString	SVGActionWriter::GetPathString( const PolyPolygon& rPolyPoly,
             aPathData += aComma;
             aPathData += GetValueString( aPolyPoint.Y() );
             sal_Char nCurrentMode = 0;
+            sal_uInt16 n = 1;
 
             while( n < nSize )
             {
@@ -1072,7 +1073,7 @@ void SVGActionWriter::ImplWriteText( const Point& rPos, const String& rText,
                                      const NMSP_RTL::OUString* pStyle,
                                      Color aTextColor )
 {
-    long nLen = rText.Len(), i;
+    long nLen = rText.Len();
 
     if( nLen )
     {
@@ -1102,7 +1103,7 @@ void SVGActionWriter::ImplWriteText( const Point& rPos, const String& rText,
             {
                 const double fFactor = (double) nWidth / aNormSize.Width();
 
-                for( i = 0; i < ( nLen - 1 ); i++ )
+                for(long i = 0; i < ( nLen - 1 ); i++ )
                     pDX[ i ] = FRound( pDX[ i ] * fFactor );
             }
         }


More information about the Libreoffice-commits mailing list