summaryrefslogtreecommitdiffstats
path: root/lotuswordpro
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-02-28 20:53:34 +0000
committerCaolán McNamara <caolanm@redhat.com>2017-02-28 20:53:34 +0000
commit26ea6d50b3f0f82d4035b367811f8edcc49ee23e (patch)
tree7c0c31a1db5ecfba3c6928caf631e067e7ff4a89 /lotuswordpro
parentofz: timeout on clamping big double to 0..360 (diff)
downloadcore-26ea6d50b3f0f82d4035b367811f8edcc49ee23e.tar.gz
core-26ea6d50b3f0f82d4035b367811f8edcc49ee23e.zip
fix leak
Change-Id: Ia073517977648a21d7adb5ee4d7bda51b1b7db18
Diffstat (limited to 'lotuswordpro')
-rw-r--r--lotuswordpro/source/filter/lwpfootnote.cxx16
1 files changed, 8 insertions, 8 deletions
diff --git a/lotuswordpro/source/filter/lwpfootnote.cxx b/lotuswordpro/source/filter/lwpfootnote.cxx
index b8ac3fd027f5..dbf35dbe5acb 100644
--- a/lotuswordpro/source/filter/lwpfootnote.cxx
+++ b/lotuswordpro/source/filter/lwpfootnote.cxx
@@ -103,28 +103,28 @@ void LwpFribFootnote::XFConvert(XFContentContainer* pCont)
LwpFootnote* pFootnote = GetFootnote();
if(pFootnote)
{
- XFContentContainer* pContent = nullptr;
+ rtl::Reference<XFContentContainer> xContent;
if(pFootnote->GetType() == FN_FOOTNOTE)
{
- pContent = new XFFootNote();
+ xContent.set(new XFFootNote);
}
else
{
- pContent = new XFEndNote();
+ xContent.set(new XFEndNote);
}
- pFootnote->XFConvert(pContent);
- if(m_ModFlag)
+ pFootnote->XFConvert(xContent.get());
+ if (m_ModFlag)
{
//set footnote number font style
- XFTextSpan *pSpan = new XFTextSpan();
+ XFTextSpan *pSpan = new XFTextSpan;
pSpan->SetStyleName(GetStyleName());
//add the xffootnote into the content container
- pSpan->Add(pContent);
+ pSpan->Add(xContent.get());
pCont->Add(pSpan);
}
else
{
- pCont->Add(pContent);
+ pCont->Add(xContent.get());
}
}
}