summaryrefslogtreecommitdiff
path: root/slideshow/source/engine/slideshowimpl.cxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolan.mcnamara@collabora.com>2024-08-05 16:03:44 +0100
committerCaolán McNamara <caolan.mcnamara@collabora.com>2024-08-06 22:31:21 +0200
commit40686d6c2fcccadc2004f187c443f105ef5fe070 (patch)
tree9a5b06ec8de57d093aa31b2fc6760bd574bc8759 /slideshow/source/engine/slideshowimpl.cxx
parent981c5780da8ec6b6878de58909b7cc7e736ad33a (diff)
cid#1607096 silence Overflowed constant
Change-Id: Ifa89ef67ffd7f5842c60a34f6705365f3de94770 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171570 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Diffstat (limited to 'slideshow/source/engine/slideshowimpl.cxx')
-rw-r--r--slideshow/source/engine/slideshowimpl.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/slideshow/source/engine/slideshowimpl.cxx b/slideshow/source/engine/slideshowimpl.cxx
index 7a6d5e8f34d3..e9df84afe339 100644
--- a/slideshow/source/engine/slideshowimpl.cxx
+++ b/slideshow/source/engine/slideshowimpl.cxx
@@ -1608,14 +1608,15 @@ void SlideShowImpl::registerUserPaintPolygons( const uno::Reference< lang::XMult
if (aPoly.count() > 1) // otherwise skip it, count should be 2
{
- if (aDrawingPoints.count() == 0)
+ const auto ptCount = aDrawingPoints.count();
+ if (ptCount == 0)
{
aDrawingPoints.append(aPoly);
pFirstPolyPoly = pPolyPoly;
continue;
}
basegfx::B2DPoint aLast
- = aDrawingPoints.getB2DPoint(aDrawingPoints.count() - 1);
+ = aDrawingPoints.getB2DPoint(ptCount - 1);
if (aPoly.getB2DPoint(0).equal(aLast))
{
aDrawingPoints.append(aPoly, 1);