lotuswordpro/source/filter/lwpsilverbullet.cxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
New commits: commit 299a1ef9f2197f253ac887bac46d6e0dcd0d6378 Author: Caolán McNamara <caol...@redhat.com> Date: Mon Feb 27 15:05:20 2017 +0000 ofz: fix leak Change-Id: I7f490335efef71b13aae66e9467cd74429509d7d diff --git a/lotuswordpro/source/filter/lwpsilverbullet.cxx b/lotuswordpro/source/filter/lwpsilverbullet.cxx index 4446aed..b837023 100644 --- a/lotuswordpro/source/filter/lwpsilverbullet.cxx +++ b/lotuswordpro/source/filter/lwpsilverbullet.cxx @@ -107,7 +107,7 @@ void LwpSilverBullet::Read() */ void LwpSilverBullet::RegisterStyle() { - XFListStyle* pListStyle = new XFListStyle(); + std::unique_ptr<XFListStyle> xListStyle(new XFListStyle()); XFStyleManager* pXFStyleManager = LwpGlobalMgr::GetInstance()->GetXFStyleManager(); GetBulletPara(); @@ -146,11 +146,11 @@ void LwpSilverBullet::RegisterStyle() } //set numbering format into the style-list. - pListStyle->SetListNumber(nPos, aFmt, pParaNumber->GetStart()+1); + xListStyle->SetListNumber(nPos, aFmt, pParaNumber->GetStart()+1); if (bCumulative && nPos > 1) { - pListStyle->SetDisplayLevel(nPos, nDisplayLevel); + xListStyle->SetDisplayLevel(nPos, nDisplayLevel); } } @@ -166,18 +166,18 @@ void LwpSilverBullet::RegisterStyle() aSuffix = aParaNumbering.pSuffix->GetText(); } - pListStyle->SetListBullet(nPos, GetNumCharByStyleID(pParaNumber), + xListStyle->SetListBullet(nPos, GetNumCharByStyleID(pParaNumber), "Times New Roman", aPrefix, aSuffix); } - pListStyle->SetListPosition(nPos, 0.0, 0.635, 0.0); + xListStyle->SetListPosition(nPos, 0.0, 0.635, 0.0); aParaNumbering.clear(); } } } //add style-list to style manager. - m_strStyleName = pXFStyleManager->AddStyle(pListStyle).m_pStyle->GetStyleName(); + m_strStyleName = pXFStyleManager->AddStyle(xListStyle.release()).m_pStyle->GetStyleName(); } /**
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits