[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/source

Caolán McNamara caolanm at redhat.com
Thu Nov 13 01:13:21 PST 2014


 vcl/source/filter/graphicfilter.cxx |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 89d74f0735d943b58393c309d0f080499d6ecdd9
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Nov 12 11:53:25 2014 +0000

    valgrind: logic for last-ditch svg detection is busted
    
    bIsGZip was never set, and the condition that uses it is additionally inverted
    
    Change-Id: I0496bb27435c4323d74c1b99467d3ede68e7bee6
    (cherry picked from commit 631378fe110ec7c4161a6c36011640522b881c27)
    Reviewed-on: https://gerrit.libreoffice.org/12382
    Reviewed-by: David Tardon <dtardon at redhat.com>
    Tested-by: David Tardon <dtardon at redhat.com>

diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx
index 2274e83..6a8dc5b 100644
--- a/vcl/source/filter/graphicfilter.cxx
+++ b/vcl/source/filter/graphicfilter.cxx
@@ -662,6 +662,8 @@ static bool ImpPeekGraphicFormat( SvStream& rStream, OUString& rFormatExtension,
             nCheckSize = nDecompressedSize < 256 ? nDecompressedSize : 256;
             aCodec.EndCompression();
             pCheckArray = sExtendedOrDecompressedFirstBytes;
+
+            bIsGZip = true;
         }
 
         bool bIsSvg(false);
@@ -696,7 +698,7 @@ static bool ImpPeekGraphicFormat( SvStream& rStream, OUString& rFormatExtension,
 
             pCheckArray = sExtendedOrDecompressedFirstBytes;
 
-            if(!bIsGZip)
+            if (bIsGZip)
             {
                 nCheckSize = nDecompressedSize < 2048 ? nDecompressedSize : 2048;
             }


More information about the Libreoffice-commits mailing list