summaryrefslogtreecommitdiff
path: root/sax
diff options
context:
space:
mode:
Diffstat (limited to 'sax')
-rw-r--r--sax/source/expatwrap/sax_expat.cxx35
1 files changed, 16 insertions, 19 deletions
diff --git a/sax/source/expatwrap/sax_expat.cxx b/sax/source/expatwrap/sax_expat.cxx
index 0dd3afdf7ebb..49f9471b7b03 100644
--- a/sax/source/expatwrap/sax_expat.cxx
+++ b/sax/source/expatwrap/sax_expat.cxx
@@ -384,27 +384,24 @@ SaxExpatParser::initialize(css::uno::Sequence< css::uno::Any > const& rArguments
}
}
-namespace
+class ParserCleanup
{
- class ParserCleanup
+private:
+ SaxExpatParser_Impl& m_rParser;
+ Entity& m_rEntity;
+public:
+ ParserCleanup(SaxExpatParser_Impl& rParser, Entity& rEntity)
+ : m_rParser(rParser)
+ , m_rEntity(rEntity)
{
- private:
- SaxExpatParser_Impl& m_rParser;
- Entity& m_rEntity;
- public:
- ParserCleanup(SaxExpatParser_Impl& rParser, Entity& rEntity)
- : m_rParser(rParser)
- , m_rEntity(rEntity)
- {
- }
- ~ParserCleanup()
- {
- m_rParser.popEntity();
- //XML_ParserFree accepts a null arg
- XML_ParserFree(m_rEntity.pParser);
- }
- };
-}
+ }
+ ~ParserCleanup()
+ {
+ m_rParser.popEntity();
+ //XML_ParserFree accepts a null arg
+ XML_ParserFree(m_rEntity.pParser);
+ }
+};
/***************
*