From cdf8e971d5d46df4bcab35a99c4254df9459213f Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Sun, 8 May 2022 13:06:00 +0200 Subject: osl::Mutex->std::mutex in SaxExpatParser Change-Id: I9d99497dfbc67cd4dd690da9db58aab0db114d36 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134021 Tested-by: Jenkins Reviewed-by: Noel Grandin --- sax/source/expatwrap/sax_expat.cxx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'sax/source/expatwrap/sax_expat.cxx') diff --git a/sax/source/expatwrap/sax_expat.cxx b/sax/source/expatwrap/sax_expat.cxx index a50fb9e024a7..78b7e2252da0 100644 --- a/sax/source/expatwrap/sax_expat.cxx +++ b/sax/source/expatwrap/sax_expat.cxx @@ -20,6 +20,7 @@ #include #include #include +#include #include #include #include @@ -146,7 +147,7 @@ constexpr OUStringLiteral gsCDATA = u"CDATA"; class SaxExpatParser_Impl { public: // module scope - Mutex aMutex; + std::mutex aMutex; bool m_bEnableDoS; // fdo#60471 thank you Adobe Illustrator css::uno::Reference< XDocumentHandler > rDocumentHandler; @@ -378,7 +379,7 @@ SaxExpatParser::initialize(css::uno::Sequence< css::uno::Any > const& rArguments OUString str; if ((rArguments[0] >>= str) && "DoSmeplease" == str) { - MutexGuard guard( m_pImpl->aMutex ); + std::unique_lock guard( m_pImpl->aMutex ); m_pImpl->m_bEnableDoS = true; } } @@ -412,7 +413,7 @@ public: void SaxExpatParser::parseStream( const InputSource& structSource) { // Only one text at one time - MutexGuard guard( m_pImpl->aMutex ); + std::unique_lock guard( m_pImpl->aMutex ); struct Entity entity; -- cgit