Kaydet (Commit) 5090d575 authored tarafından Caolán McNamara's avatar Caolán McNamara

ofz#5909 Null-dereference READ

Change-Id: I830d3e8bda517e7681cea7481c32457486ced693
Reviewed-on: https://gerrit.libreoffice.org/49218Tested-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 2029a593
<table><td><a class="sdfootnoteanc"href=" sdfootnote1 "></a><div id="sdfootnote1"><table><td>
\ No newline at end of file
......@@ -2296,6 +2296,12 @@ void HTMLTable::MakeTable( SwTableBox *pBox, sal_uInt16 nAbsAvail,
break;
}
if (!m_pSwTable)
{
SAL_WARN("sw.html", "no table");
return;
}
// get the table format and adapt it
SwFrameFormat *pFrameFormat = m_pSwTable->GetFrameFormat();
pFrameFormat->SetFormatAttr( SwFormatHoriOrient(0, eHoriOri) );
......@@ -5196,8 +5202,9 @@ std::shared_ptr<HTMLTable> SwHTMLParser::BuildTable(SvxAdjust eParentAdjust,
m_bUpperSpace = true;
SetTextCollAttrs();
m_nParaCnt = m_nParaCnt - std::min(m_nParaCnt,
pTCntxt->GetTableNode()->GetTable().GetTabSortBoxes().size());
SwTableNode* pTableNode = pTCntxt->GetTableNode();
size_t nTableBoxSize = pTableNode ? pTableNode->GetTable().GetTabSortBoxes().size() : 0;
m_nParaCnt = m_nParaCnt - std::min(m_nParaCnt, nTableBoxSize);
// Jump to a table if needed
if( JUMPTO_TABLE == m_eJumpTo && m_xTable->GetSwTable() &&
......
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