[Libreoffice-commits] core.git: sc/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Tue Apr 6 13:12:12 UTC 2021
sc/source/filter/excel/xiescher.cxx | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
New commits:
commit fda4cdc88fc28d906e3d801b7569fa7fdeda4c29
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Sun Apr 4 21:05:25 2021 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Tue Apr 6 15:11:27 2021 +0200
cid#1474130 silence Untrusted loop bound
Change-Id: I62c8bba9666bcad2513d465063a0d2ec6e72119e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113656
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx
index dd82a0c2f67c..599135666e47 100644
--- a/sc/source/filter/excel/xiescher.cxx
+++ b/sc/source/filter/excel/xiescher.cxx
@@ -2717,8 +2717,12 @@ void XclImpListBoxObj::ReadFullLbsData( XclImpStream& rStrm, std::size_t nRecLef
ReadLbsData( rStrm );
OSL_ENSURE( (rStrm.GetRecPos() == nRecEnd) || (rStrm.GetRecPos() + mnEntryCount == nRecEnd),
"XclImpListBoxObj::ReadFullLbsData - invalid size of OBJLBSDATA record" );
- while( rStrm.IsValid() && (rStrm.GetRecPos() < nRecEnd) )
+ while (rStrm.IsValid())
+ {
+ if (rStrm.GetRecPos() >= nRecEnd)
+ break;
maSelection.push_back( rStrm.ReaduInt8() );
+ }
}
void XclImpListBoxObj::DoReadObj5( XclImpStream& rStrm, sal_uInt16 nNameLen, sal_uInt16 /*nMacroSize*/ )
More information about the Libreoffice-commits
mailing list