summaryrefslogtreecommitdiff
path: root/svl
diff options
context:
space:
mode:
authorArmin Le Grand <alg@apache.org>2012-06-26 12:36:31 +0000
committerArmin Le Grand <alg@apache.org>2012-06-26 12:36:31 +0000
commitaee8221b3fbe64d8e88aa3a1b630214807cd86f0 (patch)
tree36baf6e274263a858098251f51748b8e74ead3b8 /svl
parent7933660309d98db31e5947bb35c958a7adc9143c (diff)
#120077# Memory leak fixed in ScXMLFontAutoStylePool_Impl, also chekced and fixed memory leaks caused by not deleting SfxStyleSheetIterator instances.
Found by: Chao Huang Patch by: Chao Huang Review by: alg
Notes
Diffstat (limited to 'svl')
-rw-r--r--svl/inc/svl/style.hxx1
-rw-r--r--svl/source/items/style.cxx12
2 files changed, 1 insertions, 12 deletions
diff --git a/svl/inc/svl/style.hxx b/svl/inc/svl/style.hxx
index d35429f0f5a6..478e966e8836 100644
--- a/svl/inc/svl/style.hxx
+++ b/svl/inc/svl/style.hxx
@@ -238,7 +238,6 @@ public:
SfxItemPool& GetPool();
const SfxItemPool& GetPool() const;
- virtual SfxStyleSheetIterator* CreateIterator(SfxStyleFamily, sal_uInt16 nMask);
virtual sal_uInt16 Count();
virtual SfxStyleSheetBase* operator[](sal_uInt16 nIdx);
diff --git a/svl/source/items/style.cxx b/svl/source/items/style.cxx
index 079907c99dcd..b08555cdee21 100644
--- a/svl/source/items/style.cxx
+++ b/svl/source/items/style.cxx
@@ -587,7 +587,7 @@ SfxStyleSheetIterator& SfxStyleSheetBasePool::GetIterator_Impl()
if( !rpIter || (rpIter->GetSearchMask() != nMask) || (rpIter->GetSearchFamily() != nSearchFamily) )
{
delete rpIter;
- rpIter = CreateIterator( nSearchFamily, nMask );
+ rpIter = new SfxStyleSheetIterator( this, nSearchFamily, nMask );
}
return *rpIter;
}
@@ -668,16 +668,6 @@ String SfxStyleSheetBasePool::GetStreamName()
-SfxStyleSheetIterator* SfxStyleSheetBasePool::CreateIterator
-(
- SfxStyleFamily eFam,
- sal_uInt16 mask
-)
-{
- return new SfxStyleSheetIterator(this,eFam,mask);
-}
-
-
SfxStyleSheetBase* SfxStyleSheetBasePool::Create
(
const XubString& rName,