summaryrefslogtreecommitdiffstats
path: root/lotuswordpro/source/filter/lwpfnlayout.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'lotuswordpro/source/filter/lwpfnlayout.cxx')
-rw-r--r--lotuswordpro/source/filter/lwpfnlayout.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/lotuswordpro/source/filter/lwpfnlayout.cxx b/lotuswordpro/source/filter/lwpfnlayout.cxx
index fbbdcb6b4873..0cdede0560d4 100644
--- a/lotuswordpro/source/filter/lwpfnlayout.cxx
+++ b/lotuswordpro/source/filter/lwpfnlayout.cxx
@@ -59,6 +59,7 @@
*/
#include "lwpfnlayout.hxx"
+#include <o3tl/sorted_vector.hxx>
LwpFootnoteLayout::LwpFootnoteLayout(LwpObjectHeader const& objHdr, LwpSvStream* pStrm)
: LwpTableLayout(objHdr, pStrm)
@@ -111,12 +112,16 @@ void LwpFnRowLayout::RegisterStyle()
LwpObjectID* pCellID = &GetChildHead();
LwpCellLayout* pCellLayout = dynamic_cast<LwpCellLayout*>(pCellID->obj().get());
+ o3tl::sorted_vector<LwpCellLayout*> aSeen;
while (pCellLayout)
{
+ aSeen.insert(pCellLayout);
pCellLayout->SetFoundry(m_pFoundry);
pCellLayout->RegisterStyle();
pCellID = &pCellLayout->GetNext();
pCellLayout = dynamic_cast<LwpCellLayout*>(pCellID->obj().get());
+ if (aSeen.find(pCellLayout) != aSeen.end())
+ throw std::runtime_error("loop in conversion");
}
}