[Libreoffice-commits] core.git: Branch 'libreoffice-5-1' - lotuswordpro/source
Caolán McNamara
caolanm at redhat.com
Thu Dec 17 02:54:18 PST 2015
lotuswordpro/source/filter/lwpfrib.cxx | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
New commits:
commit 51a1b41ab4a840544e5454d1d4234b443edd5466
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Dec 17 10:52:13 2015 +0000
guard against null Foundry
Change-Id: I8aabc68e8dfb9376cafe4cc709b18344da083a01
(cherry picked from commit 2f0fba494e78ede3b6691534983f6dd7e0677a7e)
diff --git a/lotuswordpro/source/filter/lwpfrib.cxx b/lotuswordpro/source/filter/lwpfrib.cxx
index d9ae6f0..2c69886 100644
--- a/lotuswordpro/source/filter/lwpfrib.cxx
+++ b/lotuswordpro/source/filter/lwpfrib.cxx
@@ -246,14 +246,14 @@ void LwpFrib::RegisterStyle(LwpFoundry* pFoundry)
m_StyleName.clear();
XFStyleManager* pXFStyleManager = LwpGlobalMgr::GetInstance()->GetXFStyleManager();
XFTextStyle* pNamedStyle = nullptr;
- if (m_pModifiers->HasCharStyle)
+ if (m_pModifiers->HasCharStyle && pFoundry)
{
pNamedStyle = static_cast<XFTextStyle*>
(pFoundry->GetStyleManager()->GetStyle(m_pModifiers->CharStyleID));
}
if (pNamedStyle)
{
- if (m_pModifiers->FontID)
+ if (m_pModifiers->FontID && pFoundry)
{
pStyle = new XFTextStyle();
*pStyle = *pNamedStyle;
@@ -273,7 +273,7 @@ void LwpFrib::RegisterStyle(LwpFoundry* pFoundry)
}
else
{
- if (m_pModifiers->FontID)
+ if (m_pModifiers->FontID && pFoundry)
{
pStyle = new XFTextStyle();
pFont = pFoundry->GetFontManger().CreateFont(m_pModifiers->FontID);
More information about the Libreoffice-commits
mailing list