Kaydet (Commit) 25c25f85 authored tarafından David Tardon's avatar David Tardon

tdf#90028 avoid crash if style is not found

Change-Id: I4ffc8cdcb67ecb4c4afa641c9219dd465fe13d29
üst ef0340bd
...@@ -1201,13 +1201,17 @@ void LwpTableLayout::PostProcessParagraph(XFCell *pCell, sal_uInt16 nRowID, sal_ ...@@ -1201,13 +1201,17 @@ void LwpTableLayout::PostProcessParagraph(XFCell *pCell, sal_uInt16 nRowID, sal_
} }
XFParaStyle * pStyle = pXFStyleManager->FindParaStyle(pXFPara->GetStyleName()); XFParaStyle * pStyle = pXFStyleManager->FindParaStyle(pXFPara->GetStyleName());
if (pStyle->GetNumberRight() || bColorMod) if ((pStyle && pStyle->GetNumberRight()) || bColorMod)
{ {
XFParaStyle* pOverStyle = new XFParaStyle; XFParaStyle* pOverStyle = new XFParaStyle;
*pOverStyle = *pStyle;
if (pStyle->GetNumberRight()) if (pStyle)
pOverStyle->SetAlignType(enumXFAlignEnd); {
*pOverStyle = *pStyle;
if (pStyle->GetNumberRight())
pOverStyle->SetAlignType(enumXFAlignEnd);
}
if (bColorMod) if (bColorMod)
{ {
......
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