summaryrefslogtreecommitdiff
path: root/lotuswordpro
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2018-01-05 10:21:11 +0000
committerCaolán McNamara <caolanm@redhat.com>2018-01-05 15:21:17 +0100
commit60b7024e95d6943a113bf58506352bd337f0392e (patch)
tree8c474d7b5a8a50797aebe8f1d50ddd2163b49a98 /lotuswordpro
parent64f1d7ad58f7281c757411b7e890e220485a09bf (diff)
ofz#4966 loop in text styles
Change-Id: If94e32689c6742b2080c213796e27d49ebe6df74 Reviewed-on: https://gerrit.libreoffice.org/47458 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'lotuswordpro')
-rw-r--r--lotuswordpro/source/filter/lwpdoc.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/lotuswordpro/source/filter/lwpdoc.cxx b/lotuswordpro/source/filter/lwpdoc.cxx
index 90fd7374869c..f12838a07095 100644
--- a/lotuswordpro/source/filter/lwpdoc.cxx
+++ b/lotuswordpro/source/filter/lwpdoc.cxx
@@ -237,6 +237,8 @@ void LwpDocument::RegisterTextStyles()
LwpTextStyle* pParaStyle = dynamic_cast<LwpTextStyle*> (pParaStyleHolder->GetHeadID().obj().get());
while(pParaStyle)
{
+ if (pParaStyle->GetFoundry())
+ throw std::runtime_error("loop in register text style");
pParaStyle->SetFoundry(m_pFoundry);
pParaStyle->RegisterStyle();
pParaStyle = dynamic_cast<LwpParaStyle*>(pParaStyle->GetNext().obj().get());