Kaydet (Commit) 6dd4cfee authored tarafından Caolán McNamara's avatar Caolán McNamara

CID#736199 out of bounds

Change-Id: I77123f6641dc1166820e3e9da583b331af53641d
üst a6baaa65
...@@ -3892,10 +3892,18 @@ bool SwTxtNode::HasVisibleNumberingOrBullet() const ...@@ -3892,10 +3892,18 @@ bool SwTxtNode::HasVisibleNumberingOrBullet() const
const SwNumRule* pRule = GetNum() ? GetNum()->GetNumRule() : 0L; const SwNumRule* pRule = GetNum() ? GetNum()->GetNumRule() : 0L;
if ( pRule && IsCountedInList()) if ( pRule && IsCountedInList())
{ {
int nLevel = GetActualListLevel();
if (nLevel < 0)
nLevel = 0;
if (nLevel >= MAXLEVEL)
nLevel = MAXLEVEL - 1;
// #i87154# // #i87154#
// Correction of #newlistlevelattrs#: // Correction of #newlistlevelattrs#:
// The numbering type has to be checked for bullet lists. // The numbering type has to be checked for bullet lists.
const SwNumFmt& rFmt = pRule->Get( static_cast<sal_uInt16>(GetActualListLevel() )); const SwNumFmt& rFmt = pRule->Get( static_cast<sal_uInt16>(nLevel ));
return SVX_NUM_NUMBER_NONE != rFmt.GetNumberingType() || return SVX_NUM_NUMBER_NONE != rFmt.GetNumberingType() ||
!pRule->MakeNumString( *(GetNum()) ).isEmpty(); !pRule->MakeNumString( *(GetNum()) ).isEmpty();
} }
......
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