To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=113743 Issue #|113743 Summary|chart2: Part of the DataSeries objects created by API |"XclImpChSeries::CreateDataSeries() const" leaks Component|Chart Version|OOO310m11 Platform|All URL| OS/Version|All Status|UNCONFIRMED Status whiteboard| Keywords| Resolution| Issue type|PATCH Priority|P2 Subcomponent|code Assigned to|iha Reported by|zhangjfibm
------- Additional comments from [email protected] Mon Aug 9 11:58:00 +0000 2010 ------- This obvious memory leak problem can be recreated with loading the sample file which has charts inside. The callstack when creating the leaked DataSeries are, chartmodelmi.dll!chart::DataSeries::DataSeries(const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 144 C++ chartmodelmi.dll!chart::DataSeries::create(const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 92 + 0x4b bytes C++ cppuhelper3MSC.dll!cppu::OSingleFactoryHelper::createInstanceEveryTime(const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 177 + 0xe bytes C++ cppuhelper3MSC.dll!cppu::OSingleFactoryHelper::createInstanceWithContext(const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 218 + 0x17 bytes C++ cppuhelper3MSC.dll!cppu::OFactoryComponentHelper::createInstanceWithContext(const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 502 + 0x11 bytes C++ cppuhelper3MSC.dll!cppu::ORegistryFactoryHelper::createInstanceEveryTime(const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 766 + 0x26 bytes C++ cppuhelper3MSC.dll!cppu::OSingleFactoryHelper::createInstanceWithContext(const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 218 + 0x17 bytes C++ cppuhelper3MSC.dll!cppu::OFactoryComponentHelper::createInstanceWithContext(const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 502 + 0x11 bytes C++ bootstrap.uno.dll!stoc_smgr::OServiceManager::createInstanceWithContext(const rtl::OUString & rServiceSpecifier={...}, const com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> & xContext={...}) Line 1276 + 0x23 bytes C++ bootstrap.uno.dll!stoc_smgr::OServiceManager::createInstance(const rtl::OUString & rServiceSpecifier={...}) Line 1386 + 0x1f bytes C++ scfiltmi.dll!ScfApiHelper::CreateInstance(com::sun::star::uno::Reference<com::sun::star::lang::XMultiServiceFactory> xFactory={...}, const rtl::OUString & rServiceName={...}) Line 94 + 0x1a bytes C++ scfiltmi.dll!ScfApiHelper::CreateInstance(const rtl::OUString & rServiceName={...}) Line 111 + 0x20 bytes C++ > scfiltmi.dll!XclImpChSeries::CreateDataSeries() Line 1735 + 0x65 bytes > C++ scfiltmi.dll!XclImpChTypeGroup::CreateDataSeries(com::sun::star::uno::Reference<com::sun::star::chart2::XChartType> xChartType={...}, long nApiAxesSetIdx=0x00000000) Line 2515 + 0x14 bytes C++ scfiltmi.dll!XclImpChTypeGroup::CreateChartType(com::sun::star::uno::Reference<com::sun::star::chart2::XDiagram> xDiagram={...}, long nApiAxesSetIdx=0x00000000) Line 2427 C++ scfiltmi.dll!XclImpChAxesSet::CreateCoordSystem(com::sun::star::uno::Reference<com::sun::star::chart2::XDiagram> xDiagram={...}) Line 3213 + 0x75 bytes C++ The root cause is that, in api "XclImpChSeries::CreateDataSeries() const", after creating the DataSeries uno object, it then calls api, > chartmodelmi.dll!chart::DataSeries::getDataPointByIndex(long nIndex=0x00000000) Line 406 C++ scfiltmi.dll!`anonymous namespace'::lclGetPointPropSet(com::sun::star::uno::Reference<com::sun::star::chart2::XDataSeries> xDataSeries={...}, unsigned short nPointIdx=0x0000) Line 1706 + 0x1e bytes C++ scfiltmi.dll!XclImpChSeries::CreateDataSeries() Line 1801 + 0x5b bytes C++ scfiltmi.dll!XclImpChTypeGroup::CreateDataSeries(com::sun::star::uno::Reference<com::sun::star::chart2::XChartType> xChartType={...}, long nApiAxesSetIdx=0x00000000) Line 2515 + 0x14 bytes C++ if you check api chart::DataSeries::getDataPointByIndex(), you may find it creates, aResult.set( new DataPoint( this )); ModifyListenerHelper::addListener( aResult, m_xModifyEventForwarder ); m_aAttributedDataPoints[ nIndex ] = aResult; This piece of code introduces cyclic reference between DataSeies and DataPoint objects stored in m_aAttributedDataPoints. To fix the problem, there must be a code point where to break the cyclic reference. --------------------------------------------------------------------- Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
