Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


Hello, I've created a very little patch to solve the next CppCheck warning (
http://libreoffice.boldandbusted.com/464.html ) . (This is my first patch in
LibreOffice)
From b7646c6393ae557c9f3e11ea68651fca0589360c Mon Sep 17 00:00:00 2001
From: Andreu Correa Casablanca <castarco@gmail.com>
Date: Sun, 11 Sep 2011 21:28:37 +0200
Subject: [PATCH] Clarified the CppCheck report: http://libreoffice.boldandbusted.com/464.html

---
 sw/source/core/crsr/findfmt.cxx |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/sw/source/core/crsr/findfmt.cxx b/sw/source/core/crsr/findfmt.cxx
index 7a548c3..0567c6e 100644
--- a/sw/source/core/crsr/findfmt.cxx
+++ b/sw/source/core/crsr/findfmt.cxx
@@ -61,7 +61,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 !!
-- 
1.7.4.1


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.