mirror of
https://github.com/RGBCube/serenity
synced 2025-06-30 07:52:08 +00:00
Kernel: Unblock threads only on unmasked signals
Signals that were explicitly masked should not unblock threads.
This commit is contained in:
parent
81a76a30a1
commit
1397a5ab02
1 changed files with 3 additions and 0 deletions
|
@ -638,6 +638,9 @@ void Thread::send_signal(u8 signal, [[maybe_unused]] Process* sender)
|
|||
m_pending_signals |= 1 << (signal - 1);
|
||||
m_have_any_unmasked_pending_signals.store((pending_signals_for_state() & ~m_signal_mask) != 0, AK::memory_order_release);
|
||||
|
||||
if (!has_unmasked_pending_signals())
|
||||
return;
|
||||
|
||||
if (m_state == Stopped) {
|
||||
SpinlockLocker lock(m_lock);
|
||||
if (pending_signals_for_state() != 0) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue