summaryrefslogtreecommitdiff
path: root/sfx2/source/bastyp
diff options
context:
space:
mode:
Diffstat (limited to 'sfx2/source/bastyp')
-rw-r--r--sfx2/source/bastyp/fltfnc.cxx10
1 files changed, 9 insertions, 1 deletions
diff --git a/sfx2/source/bastyp/fltfnc.cxx b/sfx2/source/bastyp/fltfnc.cxx
index 8d9a70c744b3..42477d09916f 100644
--- a/sfx2/source/bastyp/fltfnc.cxx
+++ b/sfx2/source/bastyp/fltfnc.cxx
@@ -255,6 +255,14 @@ public:
, pList(0)
{
}
+ ~SfxFilterMatcher_Impl()
+ {
+ // SfxFilterMatcher_Impl::InitForIterating() will set pList to
+ // either the global filter array matcher pFilterArr, or to
+ // a new SfxFilterList_Impl.
+ if (pList != pFilterArr)
+ delete pList;
+ }
};
namespace
@@ -287,7 +295,7 @@ namespace
// previously
SfxFilterMatcherArr_Impl::iterator aEnd = aImplArr.end();
SfxFilterMatcherArr_Impl::iterator aIter =
- std::find_if(aImplArr.begin(), aEnd, hasName(rName));
+ std::find_if(aImplArr.begin(), aEnd, hasName(aName));
if (aIter != aEnd)
return *aIter;