summaryrefslogtreecommitdiffstats
path: root/lotuswordpro/source/filter/lwpfootnote.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-06-06 16:49:17 +0200
committerStephan Bergmann <sbergman@redhat.com>2014-06-06 16:49:44 +0200
commit37183595bb3b4d58682f90fd9f6713bedcb852a2 (patch)
tree1ac1fd9d69c0d09ea204173bd77721dc01bbddeb /lotuswordpro/source/filter/lwpfootnote.cxx
parentAvoid undefined mis-aligned memory access (diff)
downloadcore-37183595bb3b4d58682f90fd9f6713bedcb852a2.tar.gz
core-37183595bb3b4d58682f90fd9f6713bedcb852a2.zip
Fix memory leaks, by refcounting LwpObject
Change-Id: I1539597cd5bcabcbf0295d1acc320c503ad53604
Diffstat (limited to 'lotuswordpro/source/filter/lwpfootnote.cxx')
-rw-r--r--lotuswordpro/source/filter/lwpfootnote.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/lotuswordpro/source/filter/lwpfootnote.cxx b/lotuswordpro/source/filter/lwpfootnote.cxx
index 91e18aef27b9..1761b281915d 100644
--- a/lotuswordpro/source/filter/lwpfootnote.cxx
+++ b/lotuswordpro/source/filter/lwpfootnote.cxx
@@ -141,7 +141,7 @@ void LwpFribFootnote::XFConvert(XFContentContainer* pCont)
*/
LwpFootnote* LwpFribFootnote::GetFootnote()
{
- return dynamic_cast<LwpFootnote*>(m_Footnote.obj());
+ return dynamic_cast<LwpFootnote*>(m_Footnote.obj().get());
}
LwpFootnote::LwpFootnote(LwpObjectHeader &objHdr, LwpSvStream *pStrm)
@@ -212,7 +212,7 @@ LwpCellLayout* LwpFootnote::GetCellLayout()
LwpRowLayout* pRowLayout = pTableLayout->GetRowLayout(m_nRow);
if(pRowLayout)
{
- return dynamic_cast<LwpCellLayout*>(pRowLayout->GetChildHead()->obj());
+ return dynamic_cast<LwpCellLayout*>(pRowLayout->GetChildHead()->obj().get());
}
}
}
@@ -387,7 +387,7 @@ LwpEnSuperTableLayout* LwpFootnote::FindFootnoteTableLayout()
*/
LwpContent* LwpFootnote::FindFootnoteContent()
{
- LwpContent* pContent = dynamic_cast<LwpContent*>(m_Content.obj());
+ LwpContent* pContent = dynamic_cast<LwpContent*>(m_Content.obj().get());
//if the content has layout, the content has footnote contents;
//or looking for the celllayout and return the footnote contents.
if(pContent && pContent->GetLayout(NULL))
@@ -396,7 +396,7 @@ LwpContent* LwpFootnote::FindFootnoteContent()
LwpCellLayout* pCellLayout = GetCellLayout();
if(pCellLayout)
{
- pContent = dynamic_cast<LwpContent*>(pCellLayout->GetContent()->obj());
+ pContent = dynamic_cast<LwpContent*>(pCellLayout->GetContent()->obj().get());
}
return pContent;