diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2022-05-08 12:51:17 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-05-08 19:56:03 +0200 |
commit | e8b38f770012d2dad923c8a174ba4e9553db9afa (patch) | |
tree | 897c0b2a4788263255e25423a5aa3680055a8dfb /io | |
parent | 5393dbec555b89aa649a6ece3a58ec38538d398c (diff) |
osl::Mutex->std::mutex in OAcceptor
Change-Id: I0fa5628ff601a89ed9c74212b4986689957eab1e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134017
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'io')
-rw-r--r-- | io/source/acceptor/acceptor.cxx | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/io/source/acceptor/acceptor.cxx b/io/source/acceptor/acceptor.cxx index 79af13d385b9..af0883be9769 100644 --- a/io/source/acceptor/acceptor.cxx +++ b/io/source/acceptor/acceptor.cxx @@ -17,8 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include <osl/mutex.hxx> - #include <cppuhelper/implbase.hxx> #include <cppuhelper/supportsservice.hxx> #include <cppuhelper/unourl.hxx> @@ -33,6 +31,7 @@ #include "acceptor.hxx" #include <memory> +#include <mutex> #include <string_view> using namespace ::osl; @@ -61,7 +60,7 @@ namespace { private: std::unique_ptr<io_acceptor::PipeAcceptor> m_pPipe; std::unique_ptr<io_acceptor::SocketAcceptor> m_pSocket; - Mutex m_mutex; + std::mutex m_mutex; OUString m_sLastDescription; bool m_bInAccept; @@ -136,7 +135,7 @@ Reference< XConnection > OAcceptor::accept( const OUString &sConnectionDescripti catch( ... ) { { - MutexGuard g( m_mutex ); + std::unique_lock g( m_mutex ); m_pPipe.reset(); } throw; @@ -169,7 +168,7 @@ Reference< XConnection > OAcceptor::accept( const OUString &sConnectionDescripti catch( ... ) { { - MutexGuard g( m_mutex ); + std::unique_lock g( m_mutex ); m_pSocket.reset(); } throw; @@ -212,7 +211,7 @@ Reference< XConnection > OAcceptor::accept( const OUString &sConnectionDescripti void SAL_CALL OAcceptor::stopAccepting( ) { - MutexGuard guard( m_mutex ); + std::unique_lock guard( m_mutex ); if( m_pPipe ) { |