[Libreoffice-commits] core.git: editeng/source
Stephan Bergmann
sbergman at redhat.com
Sun Jan 28 20:49:45 UTC 2018
editeng/source/accessibility/AccessibleStaticTextBase.cxx | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
New commits:
commit e9b8d6f651dff18e93f26d9c885a7a735e841021
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Sun Jan 28 11:25:10 2018 +0100
Remove useless checks against SAL_MAX_INT32
...changed from checks against USHRT_MAX in
2af1f5691e8d64afd5246d245d7876b5a2cd5cd8 "resolved fdo#35756 import more than
64k HTML table cells"
Change-Id: I32c0e1216d5ba6b1a899540dddade06b17ad0103
Reviewed-on: https://gerrit.libreoffice.org/48772
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman at redhat.com>
diff --git a/editeng/source/accessibility/AccessibleStaticTextBase.cxx b/editeng/source/accessibility/AccessibleStaticTextBase.cxx
index 10805ce72564..f22752627da3 100644
--- a/editeng/source/accessibility/AccessibleStaticTextBase.cxx
+++ b/editeng/source/accessibility/AccessibleStaticTextBase.cxx
@@ -86,9 +86,9 @@ namespace accessibility
ESelection MakeSelection( sal_Int32 nStartPara, sal_Int32 nStartIndex,
sal_Int32 nEndPara, sal_Int32 nEndIndex )
{
- DBG_ASSERT(nStartPara >= 0 && nStartPara <= SAL_MAX_INT32 &&
+ DBG_ASSERT(nStartPara >= 0 &&
nStartIndex >= 0 && nStartIndex <= USHRT_MAX &&
- nEndPara >= 0 && nEndPara <= SAL_MAX_INT32 &&
+ nEndPara >= 0 &&
nEndIndex >= 0 && nEndIndex <= USHRT_MAX ,
"AccessibleStaticTextBase_Impl::MakeSelection: index value overflow");
@@ -300,7 +300,7 @@ namespace accessibility
if( nCurrIndex >= nFlatIndex )
{
// check overflow
- DBG_ASSERT(nCurrPara >= 0 && nCurrPara <= SAL_MAX_INT32 &&
+ DBG_ASSERT(nCurrPara >= 0 &&
nFlatIndex - nCurrIndex + nCurrCount >= 0 && nFlatIndex - nCurrIndex + nCurrCount <= USHRT_MAX ,
"AccessibleStaticTextBase_Impl::Index2Internal: index value overflow");
@@ -312,7 +312,7 @@ namespace accessibility
if( bExclusive && nCurrIndex == nFlatIndex )
{
// check overflow
- DBG_ASSERT(nCurrPara > 0 && nCurrPara <= SAL_MAX_INT32 &&
+ DBG_ASSERT(nCurrPara > 0 &&
nFlatIndex - nCurrIndex + nCurrCount >= 0 && nFlatIndex - nCurrIndex + nCurrCount <= USHRT_MAX ,
"AccessibleStaticTextBase_Impl::Index2Internal: index value overflow");
More information about the Libreoffice-commits
mailing list