Add a tracing entry when executing a signal handler.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24333 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
c1de3c34b3
commit
6e4432bc6f
@ -83,6 +83,28 @@ class HandleSignals : public AbstractTraceEntry {
|
||||
};
|
||||
|
||||
|
||||
class ExecuteSignalHandler : public AbstractTraceEntry {
|
||||
public:
|
||||
ExecuteSignalHandler(int signal, struct sigaction* handler)
|
||||
:
|
||||
fSignal(signal),
|
||||
fHandler((void*)handler->sa_handler)
|
||||
{
|
||||
Initialized();
|
||||
}
|
||||
|
||||
virtual void AddDump(TraceOutput& out)
|
||||
{
|
||||
out.Print("signal exec handler: signal: %d, handler: %p",
|
||||
fSignal, fHandler);
|
||||
}
|
||||
|
||||
private:
|
||||
int fSignal;
|
||||
void* fHandler;
|
||||
};
|
||||
|
||||
|
||||
class SendSignal : public AbstractTraceEntry {
|
||||
public:
|
||||
SendSignal(pid_t target, uint32 signal, uint32 flags)
|
||||
@ -388,6 +410,8 @@ handle_signals(struct thread *thread)
|
||||
if (!restart || (handler->sa_flags & SA_RESTART) == 0)
|
||||
atomic_and(&thread->flags, ~THREAD_FLAGS_RESTART_SYSCALL);
|
||||
|
||||
T(ExecuteSignalHandler(signal, handler));
|
||||
|
||||
TRACE(("### Setting up custom signal handler frame...\n"));
|
||||
arch_setup_signal_frame(thread, handler, signal,
|
||||
atomic_get(&thread->sig_block_mask));
|
||||
|
Loading…
Reference in New Issue
Block a user