cid#1606699 Overflowed constant

Change-Id: Ibd5179a015c2aa82111badb6d181294435b8ef21
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/174742
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
This commit is contained in:
Noel Grandin 2024-10-09 19:29:50 +02:00 committed by Noel Grandin
parent ce8ac330eb
commit 0216369a73

View file

@ -246,7 +246,7 @@ void ImportExcel::ReadDimensions()
nXclRow2 = maStrm.ReaduInt32();
aXclUsedArea.maFirst.mnCol = maStrm.ReaduInt16();
aXclUsedArea.maLast.mnCol = maStrm.ReaduInt16();
if( (nXclRow1 < nXclRow2) && (aXclUsedArea.GetColCount() > 1) &&
if( nXclRow2 != 0 && (nXclRow1 < nXclRow2) && (aXclUsedArea.GetColCount() > 1) &&
(nXclRow1 <= o3tl::make_unsigned( GetScMaxPos().Row() )) )
{
// Excel stores first unused row/column index