summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Morrow <acm@mongodb.com>2017-09-23 10:02:15 -0400
committerAndrew Morrow <acm@mongodb.com>2017-09-23 12:02:20 -0400
commit280981d3a4cadeb91da9fd69864924e61d7ef99a (patch)
treeab5d7aec665279bcd6fcde2c3acf77d0b23f96b3
parent7cd1ff301f9190f893b79007878baaa6b281f21c (diff)
downloadmongo-280981d3a4cadeb91da9fd69864924e61d7ef99a.tar.gz
SERVER-30135 Don't use notify_all_at_thread_exit if we might not have a std::thread
-rw-r--r--src/mongo/transport/service_executor_synchronous.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/mongo/transport/service_executor_synchronous.cpp b/src/mongo/transport/service_executor_synchronous.cpp
index e8036ba74d9..8c66e42744e 100644
--- a/src/mongo/transport/service_executor_synchronous.cpp
+++ b/src/mongo/transport/service_executor_synchronous.cpp
@@ -133,8 +133,7 @@ Status ServiceExecutorSynchronous::schedule(Task task, ScheduleFlags flags) {
}
if (_numRunningWorkerThreads.subtractAndFetch(1) == 0) {
- stdx::unique_lock<stdx::mutex> lock(_shutdownMutex);
- stdx::notify_all_at_thread_exit(_shutdownCondition, std::move(lock));
+ _shutdownCondition.notify_all();
}
});