sd/source/filter/ppt/pptin.cxx | 11 ++++------- sd/source/filter/ppt/pptin.hxx | 10 +++++----- 2 files changed, 9 insertions(+), 12 deletions(-)
New commits: commit e8a070fd1170a7452d57304d6cf979f0c9961a0e Author: Caolán McNamara <caol...@redhat.com> Date: Thu Mar 16 11:40:20 2017 +0000 ofz#877 reference to stack alloced obj outlives obj (cherry picked from commit ae174b009bcf0f84073b9ebbf01ad31b274b789e) Change-Id: I8c854e2f651f8bf0018e8249827aae0fe23057e7 Reviewed-on: https://gerrit.libreoffice.org/35272 Reviewed-by: Michael Stahl <mst...@redhat.com> Tested-by: Michael Stahl <mst...@redhat.com> diff --git a/sd/source/filter/ppt/pptin.cxx b/sd/source/filter/ppt/pptin.cxx index 8eac912e254c..74d3e45557a1 100644 --- a/sd/source/filter/ppt/pptin.cxx +++ b/sd/source/filter/ppt/pptin.cxx @@ -98,10 +98,8 @@ using namespace ::com::sun::star; SdPPTImport::SdPPTImport( SdDrawDocument* pDocument, SvStream& rDocStream, SotStorage& rStorage, SfxMedium& rMedium ) + : maParam(rDocStream, 0) { - - sal_uInt32 nImportFlags = 0; - #ifdef DBG_UTIL PropRead* pSummaryInformation = new PropRead( rStorage, OUString( "\005SummaryInformation" ) ); if ( pSummaryInformation->IsValid() ) @@ -121,7 +119,7 @@ SdPPTImport::SdPPTImport( SdDrawDocument* pDocument, SvStream& rDocStream, SotSt aPropItem.Read( aComment ); if ( aComment.indexOf( "Applixware" ) >= 0 ) { - nImportFlags |= PPT_IMPORTFLAGS_NO_TEXT_ASSERT; + maParam.nImportFlags |= PPT_IMPORTFLAGS_NO_TEXT_ASSERT; } } } @@ -129,11 +127,10 @@ SdPPTImport::SdPPTImport( SdDrawDocument* pDocument, SvStream& rDocStream, SotSt delete pSummaryInformation; #endif - PowerPointImportParam aParam( rDocStream, nImportFlags ); SvStream* pCurrentUserStream = rStorage.OpenSotStream( "Current User", STREAM_STD_READ ); if( pCurrentUserStream ) { - ReadPptCurrentUserAtom( *pCurrentUserStream, aParam.aCurrentUserAtom ); + ReadPptCurrentUserAtom(*pCurrentUserStream, maParam.aCurrentUserAtom); delete pCurrentUserStream; } @@ -153,7 +150,7 @@ SdPPTImport::SdPPTImport( SdDrawDocument* pDocument, SvStream& rDocStream, SotSt } } - pFilter = new ImplSdPPTImport( pDocument, rStorage, rMedium, aParam ); + pFilter = new ImplSdPPTImport(pDocument, rStorage, rMedium, maParam); } bool SdPPTImport::Import() diff --git a/sd/source/filter/ppt/pptin.hxx b/sd/source/filter/ppt/pptin.hxx index ef69e29c9308..bf221f945a2a 100644 --- a/sd/source/filter/ppt/pptin.hxx +++ b/sd/source/filter/ppt/pptin.hxx @@ -48,7 +48,6 @@ class ImplSdPPTImport : public SdrPowerPointImport { SfxMedium& mrMed; SotStorage& mrStorage; -// SvStream* mpPicStream; DffRecordHeader maDocHd; std::vector<OUString> maSlideNameList; bool mbDocumentFound; @@ -82,14 +81,15 @@ public: class SdPPTImport { + PowerPointImportParam maParam; ImplSdPPTImport* pFilter; - public: +public: - SdPPTImport( SdDrawDocument* pDoc, SvStream& rDocStream, SotStorage& rStorage, SfxMedium& rMed ); - ~SdPPTImport(); + SdPPTImport( SdDrawDocument* pDoc, SvStream& rDocStream, SotStorage& rStorage, SfxMedium& rMed ); + ~SdPPTImport(); - bool Import(); + bool Import(); }; #endif // INCLUDED_SD_SOURCE_FILTER_PPT_PPTIN_HXX
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits