mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-23 16:14:23 +00:00
Kernel: Fix a few Thread::block related races
We need to have a Thread lock to protect threading related operations, such as Thread::m_blocker which is used in Thread::block. Also, if a Thread::Blocker indicates that it should be unblocking immediately, don't actually block the Thread and instead return immediately in Thread::block.
This commit is contained in:
@@ -81,7 +81,7 @@ private:
|
||||
: m_completion(completion)
|
||||
{
|
||||
}
|
||||
virtual bool should_unblock(Thread&, time_t, long) override;
|
||||
virtual bool should_unblock(Thread&) override;
|
||||
virtual const char* state_string() const override { return "Waiting"; }
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user