[Libreoffice-commits] core.git: svx/source
Caolán McNamara
caolanm at redhat.com
Fri Mar 23 08:51:12 UTC 2018
svx/source/table/tablemodel.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 3c8a6b0a183e5fa78024b5e0bb83584269068c3e
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Mar 22 15:54:07 2018 +0000
ofz#7065 Integer-overflow
Change-Id: Ic8837d21d64dc6fd3623ab5d32bc902e6c34dd21
Reviewed-on: https://gerrit.libreoffice.org/51746
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/svx/source/table/tablemodel.cxx b/svx/source/table/tablemodel.cxx
index 224d6280b4a1..033af2477a45 100644
--- a/svx/source/table/tablemodel.cxx
+++ b/svx/source/table/tablemodel.cxx
@@ -1028,7 +1028,7 @@ void TableModel::optimize()
Reference< XPropertySet > xSet2( static_cast< XCellRange* >( maRows[nRow-1].get() ), UNO_QUERY_THROW );
xSet1->getPropertyValue( sHeight ) >>= nHeight1;
xSet2->getPropertyValue( sHeight ) >>= nHeight2;
- nHeight1 += nHeight2;
+ nHeight1 = o3tl::saturating_add(nHeight1, nHeight2);
xSet2->setPropertyValue( sHeight, Any( nHeight1 ) );
}
catch( Exception& )
More information about the Libreoffice-commits
mailing list