[Libreoffice-commits] core.git: lotuswordpro/source
Caolán McNamara
caolanm at redhat.com
Wed Jan 3 18:54:33 UTC 2018
lotuswordpro/source/filter/lwppara.cxx | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
New commits:
commit 2f2ce15d1e20ab0096157b50c6b482b7cc540435
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Jan 3 15:25:46 2018 +0000
ofz#4920 Direct-leak
Change-Id: I2d4dea7936b1b8bae81bf08362a7d8c1081fdf8e
Reviewed-on: https://gerrit.libreoffice.org/47325
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/lotuswordpro/source/filter/lwppara.cxx b/lotuswordpro/source/filter/lwppara.cxx
index 2a881f58d50e..cb1b40eb3c3b 100644
--- a/lotuswordpro/source/filter/lwppara.cxx
+++ b/lotuswordpro/source/filter/lwppara.cxx
@@ -727,13 +727,13 @@ void LwpPara::RegisterStyle()
//register tab style
if(m_Fribs.HasFrib(FRIB_TAG_TAB))
{
- XFParaStyle* pNewParaStyle = new XFParaStyle;
- *pNewParaStyle = *GetXFParaStyle();
+ std::unique_ptr<XFParaStyle> xNewParaStyle(new XFParaStyle);
+ *xNewParaStyle = *GetXFParaStyle();
//pOverStyle->SetStyleName("");
- RegisterTabStyle(pNewParaStyle);
+ RegisterTabStyle(xNewParaStyle.get());
if (!m_ParentStyleName.isEmpty())
- pNewParaStyle->SetParentStyleName(m_ParentStyleName);
- m_StyleName = pXFStyleManager->AddStyle(pNewParaStyle).m_pStyle->GetStyleName();
+ xNewParaStyle->SetParentStyleName(m_ParentStyleName);
+ m_StyleName = pXFStyleManager->AddStyle(xNewParaStyle.release()).m_pStyle->GetStyleName();
}
//register master page;
More information about the Libreoffice-commits
mailing list