Apache OpenOffice (AOO) Bugzilla – Issue 120662
The slave SvXMLImportContext object for SdXMLNumberFormatMemberImportContext is always leaked
Last modified: 2016-04-09 10:38:20 UTC
In api, SvXMLImportContext * SdXMLNumberFormatImportContext::CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList ) { return new SdXMLNumberFormatMemberImportContext( GetImport(), nPrefix, rLocalName, xAttrList, this, SvXMLNumFormatContext::CreateChildContext( nPrefix, rLocalName, xAttrList ) ); } The SvXMLImportContext created by SvXMLNumFormatContext::CreateChildContext( nPrefix, rLocalName, xAttrList ) is never released anywhere. This memory leak can be observed when loading any odf documents needs number format.
Created attachment 79067 [details] fix code patch Change mpSlaveContext to shared_ptr, so it can be release automatically in SvXMLNumFormatContext destructor.
Comment on attachment 79067 [details] fix code patch Remove review tag
Committed by revision 1380115.
fixed in 4.0.0