vcl/quartz/salbmp.cxx | 12 +++++++++--- vcl/source/filter/wmf/wmfwr.cxx | 1 + vcl/source/fontsubset/cff.cxx | 12 ++++-------- vcl/source/gdi/pdffontcache.hxx | 6 +++++- vcl/win/gdi/gdiimpl.cxx | 4 ++++ 5 files changed, 23 insertions(+), 12 deletions(-)
New commits: commit b00d1e37c8d178f8199a45d1c9f08cae6bcef698 Author: Jochen Nitschke <j.nitschke+loger...@ok.de> Date: Fri May 13 20:56:38 2016 +0200 cppcheck: uninitialised members in vcl and remove clear() on std::vector types in ctors Change-Id: I8e239676d46e30049d4d5886a5b8de99cadd3f45 Reviewed-on: https://gerrit.libreoffice.org/24983 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Noel Grandin <noelgran...@gmail.com> diff --git a/vcl/quartz/salbmp.cxx b/vcl/quartz/salbmp.cxx index 4a1a9f0..48906a3 100644 --- a/vcl/quartz/salbmp.cxx +++ b/vcl/quartz/salbmp.cxx @@ -445,7 +445,8 @@ private: public: explicit ImplPixelFormat8( const BitmapPalette& rPalette ) - : mrPalette( rPalette ) + : pData(nullptr) + , mrPalette(rPalette) { } virtual void StartLine( sal_uInt8* pLine ) override { pData = pLine; } @@ -476,7 +477,10 @@ private: public: explicit ImplPixelFormat4( const BitmapPalette& rPalette ) - : mrPalette( rPalette ) + : pData(nullptr) + , mrPalette(rPalette) + , mnX(0) + , mnShift(0) { } virtual void SkipPixel( sal_uInt32 nPixel ) override @@ -521,7 +525,9 @@ private: public: explicit ImplPixelFormat1( const BitmapPalette& rPalette ) - : mrPalette( rPalette ) + : pData(nullptr) + , mrPalette(rPalette) + , mnX(0) { } virtual void SkipPixel( sal_uInt32 nPixel ) override diff --git a/vcl/source/filter/wmf/wmfwr.cxx b/vcl/source/filter/wmf/wmfwr.cxx index b759697..8feb82d 100644 --- a/vcl/source/filter/wmf/wmfwr.cxx +++ b/vcl/source/filter/wmf/wmfwr.cxx @@ -151,6 +151,7 @@ WMFWriter::WMFWriter() , eDstTextAlign(ALIGN_BASELINE) , eDstHorTextAlign(W_TA_LEFT) , bDstIsClipping(false) + , bHandleAllocated{} , nDstPenHandle(0) , nDstFontHandle(0) , nDstBrushHandle(0) diff --git a/vcl/source/fontsubset/cff.cxx b/vcl/source/fontsubset/cff.cxx index ac3bf78..74725ea 100644 --- a/vcl/source/fontsubset/cff.cxx +++ b/vcl/source/fontsubset/cff.cxx @@ -424,8 +424,11 @@ CffSubsetterContext::CffSubsetterContext( const U8* pBasePtr, int nBaseLen) , mpCharStringOps(nullptr) , mpCharStringEscs(nullptr) , mnStackIdx(0) + , mnValStack{} + , mnTransVals{} , mnHintSize(0) , mnHorzHintSize(0) + , mnHintStack{} , maCharWidth(-1) { // setCharStringType( 1); @@ -1406,12 +1409,6 @@ CffLocal::CffLocal() , mnLangGroup( 0) , mbForceBold( false) { - maStemSnapH.clear(); - maStemSnapV.clear(); - maBlueValues.clear(); - maOtherBlues.clear(); - maFamilyBlues.clear(); - maFamilyOtherBlues.clear(); } CffGlobal::CffGlobal() @@ -1434,8 +1431,6 @@ CffGlobal::CffGlobal() , mnFullNameSID( 0) , mnFamilyNameSID( 0) { - maFontBBox.clear(); - // TODO; maFontMatrix.clear(); } bool CffSubsetterContext::initialCffRead() @@ -1734,6 +1729,7 @@ public: Type1Emitter::Type1Emitter( FILE* pOutFile, bool bPfbSubset) : mpFileOut( pOutFile) , mbCloseOutfile( false) +, maBuffer{} , mnEECryptR( 55665) // default eexec seed, TODO: mnEECryptSeed , mpPtr( maBuffer) , mbPfbSubset( bPfbSubset) diff --git a/vcl/source/gdi/pdffontcache.hxx b/vcl/source/gdi/pdffontcache.hxx index 8bca64e..f668629 100644 --- a/vcl/source/gdi/pdffontcache.hxx +++ b/vcl/source/gdi/pdffontcache.hxx @@ -38,7 +38,11 @@ namespace vcl std::type_info* m_typeFontFace; FontIdentifier( const PhysicalFontFace*, bool bVertical ); - FontIdentifier() : m_nFontId(0), m_bVertical( false ) {} + FontIdentifier() + : m_nFontId(0) + , m_bVertical(false) + , m_typeFontFace(nullptr) + {} // Less than needed for std::set and std::map bool operator<( const FontIdentifier& rRight ) const diff --git a/vcl/win/gdi/gdiimpl.cxx b/vcl/win/gdi/gdiimpl.cxx index 817b062..8a43898 100644 --- a/vcl/win/gdi/gdiimpl.cxx +++ b/vcl/win/gdi/gdiimpl.cxx @@ -263,7 +263,11 @@ int ImplIsPaletteEntry( BYTE nRed, BYTE nGreen, BYTE nBlue ) WinSalGraphicsImpl::WinSalGraphicsImpl(WinSalGraphics& rParent): mrParent(rParent), mbXORMode(false), + mbPen(false), mhPen(0), + mbStockPen(false), + mbBrush(false), + mbStockBrush(false), mhBrush(0) { } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits