summaryrefslogtreecommitdiff
path: root/lotuswordpro/source/filter/lwppara.hxx
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/lwppara.hxx
parent7abe976be5166845c5f43b70a0dfb38608d31356 (diff)
Fix memory leaks, by refcounting LwpObject
Change-Id: I1539597cd5bcabcbf0295d1acc320c503ad53604
Diffstat (limited to 'lotuswordpro/source/filter/lwppara.hxx')
-rw-r--r--lotuswordpro/source/filter/lwppara.hxx9
1 files changed, 5 insertions, 4 deletions
diff --git a/lotuswordpro/source/filter/lwppara.hxx b/lotuswordpro/source/filter/lwppara.hxx
index c88280a5dcfb..7482fe188aee 100644
--- a/lotuswordpro/source/filter/lwppara.hxx
+++ b/lotuswordpro/source/filter/lwppara.hxx
@@ -148,8 +148,7 @@ class LwpPara : public LwpDLVList
{
public:
LwpPara(LwpObjectHeader& objHdr, LwpSvStream* pStrm);
- virtual ~LwpPara();
-public:
+
void Read() SAL_OVERRIDE;
void RegisterStyle() SAL_OVERRIDE;
void Parse(IXFStream* pOutputStream) SAL_OVERRIDE;
@@ -276,6 +275,8 @@ protected:
MAX_INDENT_LEVELS = 10
};
private:
+ virtual ~LwpPara();
+
void OverrideAlignment(LwpAlignmentOverride* base,LwpAlignmentOverride* over,XFParaStyle* pOverStyle);//add by 1-24
void OverrideIndent(LwpIndentOverride* base,LwpIndentOverride* over,XFParaStyle* pOverStyle);
void OverrideSpacing(LwpSpacingOverride* base,LwpSpacingOverride* over,XFParaStyle* pOverStyle);
@@ -367,8 +368,8 @@ inline LwpObjectID* LwpPara::GetStoryID()
}
inline LwpStory* LwpPara::GetStory()
{
- if (m_Story.obj())
- return dynamic_cast<LwpStory*>(m_Story.obj());
+ if (m_Story.obj().is())
+ return dynamic_cast<LwpStory*>(m_Story.obj().get());
return NULL;
}