mirror of
https://github.com/RPCS3/rpcs3.git
synced 2026-11-17 11:24:36 +01:00
Try to purge thread_state::detached
It's rarely necessary, but can cause unexpected problems.
This commit is contained in:
1 parent
cb047fcc75
commit
490f58ff3c
5 files changed
+31
-31
No files matched your search
@@ -1858,11 +1858,13 @@ bool thread_base::finalize(int) noexcept
|
||||
fsoft, fhard, ctxvol, ctxinv);
|
||||
|
||||
// Return true if need to delete thread object
|
||||
const bool result = m_state.exchange(thread_state::finished) == thread_state::detached;
|
||||
const bool ok = m_state.exchange(thread_state::finished) <= thread_state::aborting;
|
||||
|
||||
// Signal waiting threads
|
||||
m_state.notify_all();
|
||||
return result;
|
||||
|
||||
// No detached thread supported atm
|
||||
return !ok;
|
||||
}
|
||||
|
||||
void thread_base::finalize() noexcept
|
||||
|
||||
Reference in new issue
Block a user