summaryrefslogtreecommitdiff
path: root/editeng/source
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-11-18 14:26:39 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-11-19 10:12:55 +0100
commit79ea745d595945e454ced9f6cacd2bb57aa51f95 (patch)
treec5b51d24f54f60a14f1626cba3989d160cdd8a63 /editeng/source
parent6e818f0a063a2db37361e42f9c49d4bb9e44945a (diff)
use FasterParser for LoadXMLExceptList_Imp
the SvXMLImport superclass of XMLVersionListImport already constructs a parser, so we can just use that one Change-Id: I33b7f70982d78d2303a62cae40335f3c04b73579 Reviewed-on: https://gerrit.libreoffice.org/83083 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'editeng/source')
-rw-r--r--editeng/source/misc/svxacorr.cxx9
1 files changed, 3 insertions, 6 deletions
diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx
index 71249b9b051e..24ff88d8e725 100644
--- a/editeng/source/misc/svxacorr.cxx
+++ b/editeng/source/misc/svxacorr.cxx
@@ -2058,19 +2058,16 @@ void SvxAutoCorrectLanguageLists::LoadXMLExceptList_Imp(
aParserInput.aInputStream = new utl::OInputStreamWrapper( *xStrm );
// get filter
- uno::Reference< xml::sax::XFastDocumentHandler > xFilter = new SvXMLExceptionListImport ( xContext, *rpLst );
+ rtl::Reference< SvXMLExceptionListImport > xImport = new SvXMLExceptionListImport ( xContext, *rpLst );
// connect parser and filter
- uno::Reference< xml::sax::XFastParser > xParser = xml::sax::FastParser::create( xContext );
uno::Reference<xml::sax::XFastTokenHandler> xTokenHandler = new SvXMLAutoCorrectTokenHandler;
- xParser->setFastDocumentHandler( xFilter );
- xParser->registerNamespace( "http://openoffice.org/2001/block-list", SvXMLAutoCorrectToken::NAMESPACE );
- xParser->setTokenHandler( xTokenHandler );
+ xImport->setTokenHandler( xTokenHandler );
// parse
try
{
- xParser->parseStream( aParserInput );
+ xImport->parseStream( aParserInput );
}
catch( const xml::sax::SAXParseException& )
{