[Libreoffice-commits] .: sw/source writerperfect/source

Julien Nabet serval2412 at kemper.freedesktop.org
Sat Jan 14 02:30:07 PST 2012


 sw/source/core/crsr/findfmt.cxx           |    2 +-
 sw/source/core/layout/ftnfrm.cxx          |    2 +-
 sw/source/core/layout/pagechg.cxx         |    2 +-
 sw/source/filter/ww8/ww8par6.cxx          |    2 +-
 writerperfect/source/filter/FontStyle.cxx |    2 +-
 5 files changed, 5 insertions(+), 5 deletions(-)

New commits:
commit 79eb7c0cab7a7b4e0583e9582ad5e7f9e81af7d7
Author: Julien Nabet <serval2412 at yahoo.fr>
Date:   Sat Jan 14 11:29:07 2012 +0100

    Some cppcheck cleaning

diff --git a/sw/source/core/crsr/findfmt.cxx b/sw/source/core/crsr/findfmt.cxx
index 058a5f4..7902ab5 100644
--- a/sw/source/core/crsr/findfmt.cxx
+++ b/sw/source/core/crsr/findfmt.cxx
@@ -59,7 +59,7 @@ sal_Bool SwPaM::Find( const SwFmt& rFmt, SwMoveFn fnMove,
     while( !bFound &&
             0 != ( pNode = ::GetNode( *pPam, bFirst, fnMove, bInReadOnly )))
     {
-        if( 0 != ( bFound = pNode->GetFmtColl() == &rFmt ))
+        if( 0 != ( bFound = (pNode->GetFmtColl() == &rFmt) ))
         {
             // wurde die FormatCollection gefunden, dann handelt es sich auf
             // jedenfall um einen SwCntntNode !!
diff --git a/sw/source/core/layout/ftnfrm.cxx b/sw/source/core/layout/ftnfrm.cxx
index 1b4a14e..d485bc1 100644
--- a/sw/source/core/layout/ftnfrm.cxx
+++ b/sw/source/core/layout/ftnfrm.cxx
@@ -3008,7 +3008,7 @@ sal_Bool SwCntntFrm::MoveFtnCntFwd( sal_Bool bMakePage, SwFtnBossFrm *pOldBoss )
         sal_Bool bSameBoss = sal_True;
         SwFtnBossFrm * const pNewBoss = pNewUpper->FindFtnBossFrm();
         //Wechseln wir die Spalte/Seite?
-        if ( sal_False == ( bSameBoss = pNewBoss == pOldBoss ) )
+        if ( sal_False == ( bSameBoss = (pNewBoss == pOldBoss) ) )
         {
             bSamePage = pOldBoss->FindPageFrm() == pNewBoss->FindPageFrm(); // Seitenwechsel?
             pNewUpper->Calc();
diff --git a/sw/source/core/layout/pagechg.cxx b/sw/source/core/layout/pagechg.cxx
index 79d7d1b..55fdefe 100644
--- a/sw/source/core/layout/pagechg.cxx
+++ b/sw/source/core/layout/pagechg.cxx
@@ -246,7 +246,7 @@ SwPageFrm::SwPageFrm( SwFrmFmt *pFmt, SwFrm* pSib, SwPageDesc *pPgDsc ) :
     //Body-Bereich erzeugen und einsetzen, aber nur wenn ich nicht gerade
     //eine Leerseite bin.
     SwDoc *pDoc = pFmt->GetDoc();
-    if ( sal_False == (bEmptyPage = pFmt == pDoc->GetEmptyPageFmt()) )
+    if ( sal_False == (bEmptyPage = (pFmt == pDoc->GetEmptyPageFmt())) )
     {
         bEmptyPage = sal_False;
         Calc();                             //Damit die PrtArea stimmt.
diff --git a/sw/source/filter/ww8/ww8par6.cxx b/sw/source/filter/ww8/ww8par6.cxx
index 4db2f04..e83b262 100644
--- a/sw/source/filter/ww8/ww8par6.cxx
+++ b/sw/source/filter/ww8/ww8par6.cxx
@@ -1540,7 +1540,7 @@ bool SwWW8ImplReader::SetFlyBordersShadow(SfxItemSet& rFlySet,
 static void FlySecur1(short& rSize, const bool bBorder)
 {
     short nMin = MINFLY +
-        bBorder ? MAX_BORDER_SIZE : MAX_EMPTY_BORDER;
+        (bBorder ? MAX_BORDER_SIZE : MAX_EMPTY_BORDER);
 
     if ( rSize < nMin )
         rSize = nMin;
diff --git a/writerperfect/source/filter/FontStyle.cxx b/writerperfect/source/filter/FontStyle.cxx
index b2d0080..7e94b4a 100644
--- a/writerperfect/source/filter/FontStyle.cxx
+++ b/writerperfect/source/filter/FontStyle.cxx
@@ -61,7 +61,7 @@ void FontStyleManager::writeFontsDeclaration(OdfDocumentHandler *pHandler) const
 {
     TagOpenElement("office:font-face-decls").write(pHandler);
     std::map<WPXString, shared_ptr<FontStyle>, ltstr>::const_iterator iter;
-    for (iter = mStyleHash.begin(); iter != mStyleHash.end(); iter++)
+    for (iter = mStyleHash.begin(); iter != mStyleHash.end(); ++iter)
     {
         (iter->second)->write(pHandler);
     }


More information about the Libreoffice-commits mailing list