From bc11369435ca51e2ff6897433d00f6b909f6a25f Mon Sep 17 00:00:00 2001 From: Ben Caimano Date: Tue, 17 Sep 2019 23:22:19 +0000 Subject: SERVER-42165 Replace uses of stdx::mutex with mongo::Mutex --- src/mongo/scripting/engine.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/mongo/scripting/engine.cpp') diff --git a/src/mongo/scripting/engine.cpp b/src/mongo/scripting/engine.cpp index b5093581889..67edb2ca277 100644 --- a/src/mongo/scripting/engine.cpp +++ b/src/mongo/scripting/engine.cpp @@ -332,7 +332,7 @@ namespace { class ScopeCache { public: void release(const string& poolName, const std::shared_ptr& scope) { - stdx::lock_guard lk(_mutex); + stdx::lock_guard lk(_mutex); if (scope->hasOutOfMemoryException()) { // make some room @@ -358,7 +358,7 @@ public: } std::shared_ptr tryAcquire(OperationContext* opCtx, const string& poolName) { - stdx::lock_guard lk(_mutex); + stdx::lock_guard lk(_mutex); for (Pools::iterator it = _pools.begin(); it != _pools.end(); ++it) { if (it->poolName == poolName) { @@ -374,7 +374,7 @@ public: } void clear() { - stdx::lock_guard lk(_mutex); + stdx::lock_guard lk(_mutex); _pools.clear(); } @@ -391,7 +391,7 @@ private: typedef std::deque Pools; // More-recently used Scopes are kept at the front. Pools _pools; // protected by _mutex - stdx::mutex _mutex; + Mutex _mutex = MONGO_MAKE_LATCH("ScopeCache::_mutex"); }; ScopeCache scopeCache; -- cgit v1.2.1