kernel: Fix missing reference to team/thread in signal events.
The signal to the team/thread is only actually sent in a deferred procedure. To ensure that the team/thread stays valid between the DPC being queued and it actually running, we need to acquire a reference. Fixes #11390, where the DPC was run after the team was already destroyed.
This commit is contained in:
@@ -52,6 +52,8 @@ struct TeamSignalEvent : SignalEvent {
|
||||
static TeamSignalEvent* Create(Team* team, uint32 signalNumber,
|
||||
int32 signalCode, int32 errorCode);
|
||||
|
||||
virtual status_t Fire();
|
||||
|
||||
protected:
|
||||
virtual void DoDPC(DPCQueue* queue);
|
||||
|
||||
@@ -69,6 +71,8 @@ struct ThreadSignalEvent : SignalEvent {
|
||||
int32 signalCode, int32 errorCode,
|
||||
pid_t sendingTeam);
|
||||
|
||||
virtual status_t Fire();
|
||||
|
||||
protected:
|
||||
virtual void DoDPC(DPCQueue* queue);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user