diff options
Diffstat (limited to 'forms/source')
-rw-r--r-- | forms/source/misc/limitedformats.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/forms/source/misc/limitedformats.cxx b/forms/source/misc/limitedformats.cxx index c40de6b23430..628a42c55892 100644 --- a/forms/source/misc/limitedformats.cxx +++ b/forms/source/misc/limitedformats.cxx @@ -243,8 +243,8 @@ namespace frm std::span<FormatEntry> pFormats = lcl_getFormatTable(m_nTableId); // seek to the nValue'th entry - OSL_ENSURE(pFormats.size() < o3tl::make_unsigned(nValue), "OLimitedFormats::getFormatKeyPropertyValue: did not find the value!"); - if (pFormats.size() < o3tl::make_unsigned(nValue)) + OSL_ENSURE(o3tl::make_unsigned(nValue) < pFormats.size(), "OLimitedFormats::getFormatKeyPropertyValue: did not find the value!"); + if (o3tl::make_unsigned(nValue) < pFormats.size()) _rValue <<= pFormats[nValue].nKey; // TODO: should use a standard format for the control type we're working for |