summaryrefslogtreecommitdiff
path: root/lotuswordpro
diff options
context:
space:
mode:
Diffstat (limited to 'lotuswordpro')
-rw-r--r--lotuswordpro/source/filter/lwpparastyle.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/lotuswordpro/source/filter/lwpparastyle.cxx b/lotuswordpro/source/filter/lwpparastyle.cxx
index b51d24b22251..b0d19ecc8b06 100644
--- a/lotuswordpro/source/filter/lwpparastyle.cxx
+++ b/lotuswordpro/source/filter/lwpparastyle.cxx
@@ -68,6 +68,7 @@
#include "lwpnumberingoverride.hxx"
#include "lwptaboverride.hxx"
#include "lwpbackgroundoverride.hxx"
+#include <o3tl/safeint.hxx>
#include <xfilter/xfdefs.hxx>
#include <xfilter/xfparastyle.hxx>
#include <xfilter/xfborders.hxx>
@@ -455,7 +456,7 @@ void LwpParaStyle::ApplyIndent(LwpPara* pPara, XFParaStyle* pParaStyle, LwpInden
Amount += pParentIndent->GetMFirst();
else if (relative == LwpIndentOverride::RELATIVE_REST)
Amount += pParentIndent->GetMRest();
- pTotalIndent->SetMAll(Amount + pTotalIndent->GetMAll());
+ pTotalIndent->SetMAll(o3tl::saturating_add(Amount, pTotalIndent->GetMAll()));
pTotalIndent->SetMRight(pParentIndent->GetMRight()+ pTotalIndent->GetMRight());
pParaStyle->SetIndent(pTotalIndent->GetFirst());