diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-09-09 11:30:26 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-09-09 11:32:28 +0200 |
commit | e5981249db34db2367bae2a2f3e7e8d9f8bd09a0 (patch) | |
tree | 0e8b1bd15802f2b57519a9ef41b929746e79f446 | |
parent | c3c3e5b0554ca3f49649c96cf0b0b1b770713532 (diff) |
loplugin:refcounting
Change-Id: Ic2ab440e011502a1df3cd658fd8a86acc5d5c31c
-rw-r--r-- | sc/source/filter/xml/xmlbodyi.cxx | 4 | ||||
-rw-r--r-- | starmath/source/mathmlimport.cxx | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/sc/source/filter/xml/xmlbodyi.cxx b/sc/source/filter/xml/xmlbodyi.cxx index 88b4a34449ad..379a3a5c0f1d 100644 --- a/sc/source/filter/xml/xmlbodyi.cxx +++ b/sc/source/filter/xml/xmlbodyi.cxx @@ -236,8 +236,8 @@ void ScXMLBodyContext::EndElement() if (!bHadCalculationSettings) { // #111055#; set calculation settings defaults if there is no calculation settings element - ScXMLCalculationSettingsContext aContext( GetScImport(), XML_NAMESPACE_TABLE, GetXMLToken(XML_CALCULATION_SETTINGS), nullptr ); - aContext.EndElement(); + rtl::Reference<ScXMLCalculationSettingsContext> pContext( new ScXMLCalculationSettingsContext(GetScImport(), XML_NAMESPACE_TABLE, GetXMLToken(XML_CALCULATION_SETTINGS), nullptr) ); + pContext->EndElement(); } ScXMLImport::MutexGuard aGuard(GetScImport()); diff --git a/starmath/source/mathmlimport.cxx b/starmath/source/mathmlimport.cxx index 2690824939bd..6e526e4e1163 100644 --- a/starmath/source/mathmlimport.cxx +++ b/starmath/source/mathmlimport.cxx @@ -2070,10 +2070,10 @@ SvXMLImportContext *SmXMLDocContext_Impl::CreateChildContext( /*Basically theres an implicit mrow around certain bare *elements, use a RowContext to see if this is one of *those ones*/ - SmXMLRowContext_Impl aTempContext(GetSmImport(),nPrefix, - GetXMLToken(XML_MROW)); + rtl::Reference<SmXMLRowContext_Impl> aTempContext(new SmXMLRowContext_Impl(GetSmImport(),nPrefix, + GetXMLToken(XML_MROW))); - pContext = aTempContext.StrictCreateChildContext(nPrefix, + pContext = aTempContext->StrictCreateChildContext(nPrefix, rLocalName, xAttrList); break; } |