summaryrefslogtreecommitdiff
path: root/svx/source/svdraw/svdobj.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-01-11 13:04:35 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-01-16 06:10:36 +0000
commit0b272cdf0025ce4bca31ee01c8b3aaca042dcb62 (patch)
treee5d3ec93289598ebfe0121e7a3d0c880c3054844 /svx/source/svdraw/svdobj.cxx
parent570d8dab6d6754ab8020cbe6624020dff7b8b624 (diff)
new loplugin: useuniqueptr: svx
Change-Id: I0eb3d43d7bcfc491df16a72997a0720a6aec2c5c Reviewed-on: https://gerrit.libreoffice.org/32959 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx/source/svdraw/svdobj.cxx')
-rw-r--r--svx/source/svdraw/svdobj.cxx8
1 files changed, 2 insertions, 6 deletions
diff --git a/svx/source/svdraw/svdobj.cxx b/svx/source/svdraw/svdobj.cxx
index d885ed3b9ed6..f62dd3100a18 100644
--- a/svx/source/svdraw/svdobj.cxx
+++ b/svx/source/svdraw/svdobj.cxx
@@ -180,7 +180,6 @@ SdrObjGeoData::SdrObjGeoData():
SdrObjGeoData::~SdrObjGeoData()
{
- delete pGPL;
}
SdrObjTransformInfoRec::SdrObjTransformInfoRec() :
@@ -1877,13 +1876,10 @@ void SdrObject::SaveGeoData(SdrObjGeoData& rGeo) const
if (rGeo.pGPL!=nullptr) {
*rGeo.pGPL=*pPlusData->pGluePoints;
} else {
- rGeo.pGPL=new SdrGluePointList(*pPlusData->pGluePoints);
+ rGeo.pGPL.reset( new SdrGluePointList(*pPlusData->pGluePoints) );
}
} else {
- if (rGeo.pGPL!=nullptr) {
- delete rGeo.pGPL;
- rGeo.pGPL=nullptr;
- }
+ rGeo.pGPL.reset();
}
}