summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-11-01 11:28:01 +0000
committerCaolán McNamara <caolanm@redhat.com>2017-11-01 16:55:31 +0100
commit0bc9547ff7ad219ae591b645052152b71cc76f6e (patch)
treef7cab331d6cad435e002c7cc5c0f45472b1c67f2 /svx
parent47efda5b9c95c89cf4dd4c4e7479a555a7615f91 (diff)
ofz#3886 Integer-overflow
Change-Id: I5f7ee16e8b05d7bb7e15ca26e0902ad0c1fed2de Reviewed-on: https://gerrit.libreoffice.org/44164 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/table/tablelayouter.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/svx/source/table/tablelayouter.cxx b/svx/source/table/tablelayouter.cxx
index ec3c24a0bed9..63ca7b8c1bcc 100644
--- a/svx/source/table/tablelayouter.cxx
+++ b/svx/source/table/tablelayouter.cxx
@@ -454,7 +454,7 @@ sal_Int32 TableLayouter::distribute( LayoutVector& rLayouts, sal_Int32 nDistribu
{
Layout& rLayout = rLayouts[nIndex];
if( (nDistribute > 0) || (rLayout.mnSize > rLayout.mnMinSize) )
- nCurrentWidth += rLayout.mnSize;
+ nCurrentWidth = o3tl::saturating_add(nCurrentWidth, rLayout.mnSize);
}
bConstrainsBroken = false;