Apache OpenOffice (AOO) Bugzilla – Issue 119991
[From Symphony] There is a memory leak in function SvxUnoDrawPool::~SvxUnoDrawPool()
Last modified: 2013-02-16 09:22:29 UTC
Steps to reproduce the issue 1) Launch Aoo3.4 2) New a odp file 3) Input in textbox 4) Save the odp file Defect : There is a memory leak in function SvxUnoDrawPool::~SvxUnoDrawPool()
The secondary pool created in function SvxUnoDrawPool::init() will not be released in function SvxUnoDrawPool::~SvxUnoDrawPool(). Need to free it explictly.
Created attachment 78330 [details] for file "main\svx\source\unodraw\unopool.cxx"
take over the bug to commit it's code.
Committed to AOO trunk by revision 1351347.
ALG: Unfortunately this leads to problems. When deleting the secondary pool first, it still has it's master set (pMaster) and asserts this. The correct way is to first delete the master pool (mpDefaultsPool) which rsets the pMaster at the pSecondaryPool, and then pSecondaryPool. See e.g. how SdrModel::~SdrModel destructs it's pool. Comitted as r1352830.
(In reply to comment #5) > ALG: Unfortunately this leads to problems. When deleting the secondary pool > first, it still has it's master set (pMaster) and asserts this. The correct > way is to first delete the master pool (mpDefaultsPool) which rsets the > pMaster at the pSecondaryPool, and then pSecondaryPool. See e.g. how > SdrModel::~SdrModel destructs it's pool. > Comitted as r1352830. hi, Armin Thanks for your correction on the sequence. I learnt a lot in this mistake. You are a nice man.
Suggest to put it into AOO 3.5.0 release
Since last SVT(r1400866) shows there is no memory leak, so close this defect as resolved.