summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/llcommon/threadpool.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/indra/llcommon/threadpool.cpp b/indra/llcommon/threadpool.cpp
index a063a01b82..c48989358e 100644
--- a/indra/llcommon/threadpool.cpp
+++ b/indra/llcommon/threadpool.cpp
@@ -120,8 +120,11 @@ void LL::ThreadPoolBase::close()
mQueue->close();
for (auto& pair: mThreads)
{
- LL_DEBUGS("ThreadPool") << mName << " waiting on thread " << pair.first << LL_ENDL;
- pair.second.join();
+ if (pair.second.joinable())
+ {
+ LL_DEBUGS("ThreadPool") << mName << " waiting on thread " << pair.first << LL_ENDL;
+ pair.second.join();
+ }
}
LL_DEBUGS("ThreadPool") << mName << " shutdown complete" << LL_ENDL;
}