summaryrefslogtreecommitdiff
path: root/sc/source/ui/docshell
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-01-17 10:11:31 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-01-19 05:39:18 +0000
commit9767537e22e178eb23872de138ea70e57c1a6725 (patch)
tree5abf4eee091215affc75477b08def703188de513 /sc/source/ui/docshell
parent7c817d73402583f1b077d31a695c565a53468887 (diff)
new loplugin: useuniqueptr: sc part 2
Change-Id: I37936a297027313e2a8ae18f355567462955739e Reviewed-on: https://gerrit.libreoffice.org/33203 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui/docshell')
-rw-r--r--sc/source/ui/docshell/dataprovider.cxx2
-rw-r--r--sc/source/ui/docshell/pagedata.cxx5
2 files changed, 1 insertions, 6 deletions
diff --git a/sc/source/ui/docshell/dataprovider.cxx b/sc/source/ui/docshell/dataprovider.cxx
index eb037edcd1b2..f309e791e088 100644
--- a/sc/source/ui/docshell/dataprovider.cxx
+++ b/sc/source/ui/docshell/dataprovider.cxx
@@ -71,7 +71,6 @@ ExternalDataMapper::ExternalDataMapper(ScDocShell* pDocShell, const OUString& rU
ExternalDataMapper::~ExternalDataMapper()
{
- delete mpDataProvider;
}
void ExternalDataMapper::StartImport()
@@ -146,7 +145,6 @@ CSVFetchThread::CSVFetchThread(SvStream *pData, size_t nColCount):
CSVFetchThread::~CSVFetchThread()
{
- delete mpStream;
}
bool CSVFetchThread::IsRequestedTerminate()
diff --git a/sc/source/ui/docshell/pagedata.cxx b/sc/source/ui/docshell/pagedata.cxx
index 7a73ae639ac7..143c1e50119f 100644
--- a/sc/source/ui/docshell/pagedata.cxx
+++ b/sc/source/ui/docshell/pagedata.cxx
@@ -68,15 +68,12 @@ ScPageBreakData::ScPageBreakData(size_t nMax)
{
nUsed = 0;
if (nMax)
- pData = new ScPrintRangeData[nMax];
- else
- pData = nullptr;
+ pData.reset( new ScPrintRangeData[nMax] );
nAlloc = nMax;
}
ScPageBreakData::~ScPageBreakData()
{
- delete[] pData;
}
ScPrintRangeData& ScPageBreakData::GetData(size_t nPos)