diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-05-27 15:55:18 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-05-28 13:28:31 +0200 |
commit | 3e0c39f9aeaa5c8791df94418ab8b4b78e005ac1 (patch) | |
tree | 95688550e260ca9a3f0841d8c5e403e9954433d1 /tools | |
parent | 6eb3d37fdc75537aa94144eef97493ec6192792f (diff) |
no need to allocate these on the heap
Change-Id: I0f477edb666ff2c6dc9def45ec68c4ce1a34634a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116289
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/source/generic/poly.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/source/generic/poly.cxx b/tools/source/generic/poly.cxx index 210764086743..f0a0a7388b06 100644 --- a/tools/source/generic/poly.cxx +++ b/tools/source/generic/poly.cxx @@ -141,12 +141,12 @@ ImplPolygon::ImplPolygon( const tools::Rectangle& rRect, sal_uInt32 nHorzRound, const Point aTR( aRect.Right() - nHorzRound, aRect.Top() + nVertRound ); const Point aBR( aRect.Right() - nHorzRound, aRect.Bottom() - nVertRound ); const Point aBL( aRect.Left() + nHorzRound, aRect.Bottom() - nVertRound ); - std::unique_ptr<tools::Polygon> pEllipsePoly( new tools::Polygon( Point(), nHorzRound, nVertRound ) ); - sal_uInt16 i, nEnd, nSize4 = pEllipsePoly->GetSize() >> 2; + tools::Polygon aEllipsePoly( Point(), nHorzRound, nVertRound ); + sal_uInt16 i, nEnd, nSize4 = aEllipsePoly.GetSize() >> 2; - ImplInitSize(pEllipsePoly->GetSize() + 1); + ImplInitSize(aEllipsePoly.GetSize() + 1); - const Point* pSrcAry = pEllipsePoly->GetConstPointAry(); + const Point* pSrcAry = aEllipsePoly.GetConstPointAry(); Point* pDstAry = mxPointAry.get(); for( i = 0, nEnd = nSize4; i < nEnd; i++ ) |