Kaydet (Commit) 9be88e72 authored tarafından Caolán McNamara's avatar Caolán McNamara

ofz#4914 Undefined-shift

Change-Id: Ie1accb0de3af652877c37ec15fe319378567431c
Reviewed-on: https://gerrit.libreoffice.org/47337Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst cb628728
...@@ -2785,11 +2785,17 @@ void SwWW8ImplReader::Read_POutLvl(sal_uInt16, const sal_uInt8* pData, short nLe ...@@ -2785,11 +2785,17 @@ void SwWW8ImplReader::Read_POutLvl(sal_uInt16, const sal_uInt8* pData, short nLe
if (m_pAktColl != nullptr) if (m_pAktColl != nullptr)
{ {
SwWW8StyInf* pSI = GetStyle(m_nAktColl); SwWW8StyInf* pSI = GetStyle(m_nAktColl);
if (pSI != nullptr) if (pSI && pSI->m_bColl && pSI->m_pFormat)
{ {
pSI->mnWW8OutlineLevel = pSI->mnWW8OutlineLevel =
static_cast< sal_uInt8 >( ( (pData && nLen >= 1) ? *pData : 0 ) ); static_cast< sal_uInt8 >( ( (pData && nLen >= 1) ? *pData : 0 ) );
NewAttr( SfxUInt16Item( RES_PARATR_OUTLINELEVEL, SwWW8StyInf::WW8OutlineLevelToOutlinelevel( pSI->mnWW8OutlineLevel ) ) ); auto nLevel = SwWW8StyInf::WW8OutlineLevelToOutlinelevel(pSI->mnWW8OutlineLevel);
if (nLevel == 0)
{
SwTextFormatColl* pTextFormatColl = static_cast<SwTextFormatColl*>(pSI->m_pFormat);
pTextFormatColl->DeleteAssignmentToListLevelOfOutlineStyle();
}
NewAttr(SfxUInt16Item(RES_PARATR_OUTLINELEVEL, nLevel));
} }
} }
else if (m_pPaM != nullptr) else if (m_pPaM != nullptr)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment