diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-03-16 10:24:40 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-03-16 10:25:41 +0000 |
commit | eca17faebdeb1a1dc305ffc9273e533eb880d4da (patch) | |
tree | 97cfa6062208ed7122a5e56f958a255d575f00fd /lotuswordpro | |
parent | c9be863a12bc7419a0a1302700f747f0a7e1052b (diff) |
ubsan: load of value 768, which is not a valid value for type
Change-Id: Ief0b70f19630d8d8cc925145848c7a2c8a2813ad
Diffstat (limited to 'lotuswordpro')
-rw-r--r-- | lotuswordpro/source/filter/lwpoverride.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lotuswordpro/source/filter/lwpoverride.cxx b/lotuswordpro/source/filter/lwpoverride.cxx index d78de247d746..5856a4c8db42 100644 --- a/lotuswordpro/source/filter/lwpoverride.cxx +++ b/lotuswordpro/source/filter/lwpoverride.cxx @@ -338,7 +338,9 @@ void LwpSpacingCommonOverride::Read(LwpObjectStream* pStrm) if (pStrm->QuickReadBool()) { ReadCommon(pStrm); - m_nSpacingType = static_cast<SpacingType>(pStrm->QuickReaduInt16()); + const sal_uInt16 nSpacingType = pStrm->QuickReaduInt16(); + //only the bottom pair of bits matter + m_nSpacingType = static_cast<SpacingType>(nSpacingType & 0x3); m_nAmount = pStrm->QuickReadInt32(); m_nMultiple = pStrm->QuickReadInt32(); } |