diff options
author | Jian Fang Zhang <zhangjf@apache.org> | 2012-09-11 12:20:33 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-05-31 14:59:58 +0100 |
commit | 275225ed4d401d306c75de92fb980a6a3f85c635 (patch) | |
tree | c5626dcc540debaf8dd9214b82dc16e2a811d2ea /chart2 | |
parent | 0badc400706d059381ec396c33dd0760042c4c0b (diff) |
Resolves: #i120828#, restore some ChartModel::dispose() calls..
to break cyclic reference
Found by: zhangjf
Patch by: zhangjf
(cherry picked from commit 1c564cb9a46fc6435750f9f1a70f654b52efd970)
Change-Id: I8aaac18584d55d9f381acdf4deb0e704bc9bcfc1
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/source/model/main/ChartModel.cxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/chart2/source/model/main/ChartModel.cxx b/chart2/source/model/main/ChartModel.cxx index e2157c4f2daa..aa5f78fd5312 100644 --- a/chart2/source/model/main/ChartModel.cxx +++ b/chart2/source/model/main/ChartModel.cxx @@ -556,6 +556,9 @@ void SAL_CALL ChartModel::dispose() throw(uno::RuntimeException) m_pUndoManager.clear(); // that's important, since the UndoManager implementation delegates its ref counting to ourself. + if( m_xOldModelAgg.is()) // #i120828#, to release cyclic reference to ChartModel object + m_xOldModelAgg->setDelegator( 0 ); + m_aControllers.disposeAndClear( lang::EventObject( static_cast< cppu::OWeakObject * >( this ))); m_xCurrentController.clear(); |