tweak for future null deref warning

Change-Id: I38590e08a6bd03a2ddfeda466b9cee7128c62aa7
This commit is contained in:
Caolán McNamara
2014-11-18 09:11:06 +00:00
parent b759504c9f
commit 5c339be474

View File

@@ -263,8 +263,8 @@ void LwpFrib::RegisterStyle(LwpFoundry* pFoundry)
pFont = pFoundry->GetFontManger().CreateOverrideFont(pCharStyle->GetFinalFontID(),m_pModifiers->FontID);
pStyle->SetFont(pFont);
IXFStyleRet aNewStyle = pXFStyleManager->AddStyle(pStyle);
m_StyleName = aNewStyle.m_pStyle->GetStyleName();
pStyle = dynamic_cast<XFTextStyle*>(aNewStyle.m_pStyle);
m_StyleName = pStyle->GetStyleName();
if (aNewStyle.m_bOrigDeleted)
pStyle = NULL;
}
@@ -279,8 +279,8 @@ void LwpFrib::RegisterStyle(LwpFoundry* pFoundry)
pFont = pFoundry->GetFontManger().CreateFont(m_pModifiers->FontID);
pStyle->SetFont(pFont);
IXFStyleRet aNewStyle = pXFStyleManager->AddStyle(pStyle);
m_StyleName = aNewStyle.m_pStyle->GetStyleName();
pStyle = dynamic_cast<XFTextStyle*>(aNewStyle.m_pStyle);
m_StyleName = pStyle->GetStyleName();
if (aNewStyle.m_bOrigDeleted)
pStyle = NULL;
}