Kernel: Switch a couple of signal dispatch dbglns to dbgln_if

These are pretty spammy when using strace.
This commit is contained in:
Idan Horowitz 2024-03-01 21:20:27 +02:00 committed by Andreas Kling
parent 06c176bbfb
commit 209c588ed1

View file

@ -964,14 +964,14 @@ DispatchSignalResult Thread::dispatch_signal(u8 signal)
}
if (signal == SIGCONT) {
dbgln("signal: SIGCONT resuming {}", *this);
dbgln_if(SIGNAL_DEBUG, "signal: SIGCONT resuming {}", *this);
} else {
if (tracer) {
// when a thread is traced, it should be stopped whenever it receives a signal
// the tracer is notified of this by using waitpid()
// only "pending signals" from the tracer are sent to the tracee
if (!tracer->has_pending_signal(signal)) {
dbgln("signal: {} stopping {} for tracer", signal, *this);
dbgln_if(SIGNAL_DEBUG, "signal: {} stopping {} for tracer", signal, *this);
set_state(Thread::State::Stopped, signal);
return DispatchSignalResult::Yield;
}