diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-10 14:39:30 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-12 08:58:36 +0200 |
commit | 61d6047727d2d6f80054094160d630bfed31ab03 (patch) | |
tree | 55707081ab38fad4be8c9787587a0aaadb951b56 /sd | |
parent | 1b88de0a07180661c4d5d6706247d546d06bc983 (diff) |
loplugin:useuniqueptr in SdPPTImport
Change-Id: I077646794b806cf66d36de87050d1c93cc96a972
Reviewed-on: https://gerrit.libreoffice.org/60343
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/filter/ppt/pptin.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sd/source/filter/ppt/pptin.cxx b/sd/source/filter/ppt/pptin.cxx index 70a5ae3ee8ed..c885ed988ac5 100644 --- a/sd/source/filter/ppt/pptin.cxx +++ b/sd/source/filter/ppt/pptin.cxx @@ -110,7 +110,7 @@ SdPPTImport::SdPPTImport( SdDrawDocument* pDocument, SvStream& rDocStream, SotSt : maParam(rDocStream) { #ifdef DBG_UTIL - PropRead* pSummaryInformation = new PropRead( rStorage, "\005SummaryInformation" ); + std::unique_ptr<PropRead> pSummaryInformation(new PropRead( rStorage, "\005SummaryInformation" )); if ( pSummaryInformation->IsValid() ) { pSummaryInformation->Read(); @@ -133,7 +133,7 @@ SdPPTImport::SdPPTImport( SdDrawDocument* pDocument, SvStream& rDocStream, SotSt } } } - delete pSummaryInformation; + pSummaryInformation.reset(); #endif SvStream* pCurrentUserStream = rStorage.OpenSotStream( "Current User", StreamMode::STD_READ ); @@ -259,7 +259,7 @@ bool ImplSdPPTImport::Import() SeekOle( pDocShell, mnFilterOptions ); // hyperlinks - PropRead* pDInfoSec2 = new PropRead( mrStorage, "\005DocumentSummaryInformation" ); + std::unique_ptr<PropRead> pDInfoSec2(new PropRead( mrStorage, "\005DocumentSummaryInformation" )); if ( pDInfoSec2->IsValid() ) { PropItem aPropItem; @@ -522,7 +522,7 @@ bool ImplSdPPTImport::Import() } } } - delete pDInfoSec2; + pDInfoSec2.reset(); if ( mbDocumentFound ) { |