[Libreoffice-commits] core.git: sd/source

Jochen Nitschke j.nitschke+logerrit at ok.de
Thu Nov 24 04:58:30 UTC 2016


 sd/source/filter/eppt/pptx-epptooxml.cxx |    1 -
 1 file changed, 1 deletion(-)

New commits:
commit adeb91e69de33f09b154ccd7f5cdc0ac6c2cfb0c
Author: Jochen Nitschke <j.nitschke+logerrit at ok.de>
Date:   Wed Nov 23 21:07:22 2016 +0100

    don't use memset on std::vector
    
    cppcheck warns:
    >    memset( mLayoutInfo, 0, sizeof(mLayoutInfo) );<--- Using 'memset'
    > on struct that contains a 'std::vector'. [-]
    mLayoutInfo is an array of LayoutInfo,
    the struct LayoutInfo holds only a std::vector.
    
    remove the memset, as non-POD type LayoutInfo is default initialized.
    
    Change-Id: I3924660e39c488abbbc94404016718242c2c0c7f
    Reviewed-on: https://gerrit.libreoffice.org/31134
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
    Tested-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx
index 8069c7a..e88be43 100644
--- a/sd/source/filter/eppt/pptx-epptooxml.cxx
+++ b/sd/source/filter/eppt/pptx-epptooxml.cxx
@@ -319,7 +319,6 @@ PowerPointExport::PowerPointExport( const Reference< XComponentContext > & rxCtx
     , mnAnimationNodeIdMax(1)
     , mbCreateNotes(false)
 {
-    memset( mLayoutInfo, 0, sizeof(mLayoutInfo) );
 }
 
 PowerPointExport::~PowerPointExport()


More information about the Libreoffice-commits mailing list