mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 08:08:12 +00:00
LibThreading: Add is_started state information to Thread
Users can now determine whether a thread has been started or not. A started thread might also have already terminated. Implementation note: We *could* detect this with pthread APIs maybe, but this is much simpler.
This commit is contained in:
parent
500dc83f32
commit
91913fba59
2 changed files with 3 additions and 0 deletions
|
@ -45,6 +45,7 @@ void Threading::Thread::start()
|
|||
VERIFY(rc == 0);
|
||||
}
|
||||
dbgln("Started thread \"{}\", tid = {}", m_thread_name, m_tid);
|
||||
m_started = true;
|
||||
}
|
||||
|
||||
void Threading::Thread::detach()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue