[Libreoffice-commits] .: sw/source

Caolán McNamara caolan at kemper.freedesktop.org
Sun Jan 2 13:32:20 PST 2011


 sw/source/filter/ww8/ww8atr.cxx |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 40cd03afad3faa40d9f7fab03c55ba376f7a1e60
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 2 21:31:27 2011 +0000

    cppcheck: the scope of these variables can be reduced

diff --git a/sw/source/filter/ww8/ww8atr.cxx b/sw/source/filter/ww8/ww8atr.cxx
index 43c3889..c56646f 100644
--- a/sw/source/filter/ww8/ww8atr.cxx
+++ b/sw/source/filter/ww8/ww8atr.cxx
@@ -3464,11 +3464,12 @@ ULONG WW8Export::ReplaceCr( BYTE nChar )
     bool bReplaced = false;
     SvStream& rStrm = Strm();
     ULONG nRetPos = 0, nPos = rStrm.Tell();
-    BYTE nBCode=0;
-    UINT16 nUCode=0;
     //If there is at least two characters already output
     if (nPos - (IsUnicode() ? 2 : 1) >= ULONG(pFib->fcMin))
     {
+        BYTE nBCode=0;
+        UINT16 nUCode=0;
+
         rStrm.SeekRel(IsUnicode() ? -2 : -1);
         if (IsUnicode())
             rStrm >> nUCode;


More information about the Libreoffice-commits mailing list