summaryrefslogtreecommitdiff
path: root/svx/source/customshapes/EnhancedCustomShape3d.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-09-06 09:14:06 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-09-06 12:50:57 +0200
commitfc161dc07cafda54ebdabd4c66dfd6528cc11813 (patch)
tree81b5ccfca3793741ac74a4591f0b6605986eabe3 /svx/source/customshapes/EnhancedCustomShape3d.cxx
parentdc79dc76f18148296ae18ed7251cf61505e25d44 (diff)
use unique_ptr in DoConvertToPolyObj
Change-Id: Ia7f9ff4d8f7b9834b6634e5c126bd65014dacf19 Reviewed-on: https://gerrit.libreoffice.org/78684 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx/source/customshapes/EnhancedCustomShape3d.cxx')
-rw-r--r--svx/source/customshapes/EnhancedCustomShape3d.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/svx/source/customshapes/EnhancedCustomShape3d.cxx b/svx/source/customshapes/EnhancedCustomShape3d.cxx
index 2d53139baea4..339f99fd3b59 100644
--- a/svx/source/customshapes/EnhancedCustomShape3d.cxx
+++ b/svx/source/customshapes/EnhancedCustomShape3d.cxx
@@ -459,11 +459,10 @@ SdrObject* EnhancedCustomShape3d::Create3DObject(
}
else
{
- SdrObject* pNewObj = pNext->ConvertToPolyObj( false, false );
- SdrPathObj* pPath = dynamic_cast<SdrPathObj*>( pNewObj );
+ SdrObjectUniquePtr pNewObj = pNext->ConvertToPolyObj( false, false );
+ SdrPathObj* pPath = dynamic_cast<SdrPathObj*>( pNewObj.get() );
if ( pPath )
aPolyPoly = pPath->GetPathPoly();
- SdrObject::Free( pNewObj );
}
if( aPolyPoly.count() )