summaryrefslogtreecommitdiff
path: root/svx/source/sdr
diff options
context:
space:
mode:
authorNoel <noelgrandin@gmail.com>2020-11-12 16:10:56 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2020-11-16 13:46:01 +0100
commit36b3b357fe2a882db6a5f5a006239e16200fb847 (patch)
treedb2a4887f6ef25dcaf3fd2c00998b6e3645592e7 /svx/source/sdr
parentdbbb5569b45ede85af7f2ee53496f28762cbf371 (diff)
replace std::min(std::max()) with std::clamp
Change-Id: I76e34e8020d98292e8ffde387542b7029f85a42d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105754 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx/source/sdr')
-rw-r--r--svx/source/sdr/primitive2d/sdrframeborderprimitive2d.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/svx/source/sdr/primitive2d/sdrframeborderprimitive2d.cxx b/svx/source/sdr/primitive2d/sdrframeborderprimitive2d.cxx
index aaa0f3d14fe7..76af6c23b68e 100644
--- a/svx/source/sdr/primitive2d/sdrframeborderprimitive2d.cxx
+++ b/svx/source/sdr/primitive2d/sdrframeborderprimitive2d.cxx
@@ -458,7 +458,7 @@ namespace
nBaseIndex = bUpper ? nVisEdgeUp : nVisEdgeDn;
}
- const size_t nSecuredIndex(std::min(nNumCutSets - 1, std::max(nBaseIndex, static_cast< size_t >(0))));
+ const size_t nSecuredIndex(std::clamp(nBaseIndex, size_t(0), size_t(nNumCutSets - 1)));
const CutSet& rCutSet(aCutSets[nSecuredIndex]);
ExtendSet& rExt(rExtendSet[my]);