mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 18:20:52 +07:00
exit signals: use of uninitialized field notify_count
task->signal->notify_count is only initialized if task->signal->group_exit_task is not NULL. Reorder a conditional so that uninitialised memory is not used. Found by Valgrind. Signed-off-by: Steve VanDeBogart <vandebo-lkml@nerdbox.net> Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
parent
7487017282
commit
2633f0e57b
@ -918,8 +918,8 @@ static void exit_notify(struct task_struct *tsk, int group_dead)
|
||||
|
||||
/* mt-exec, de_thread() is waiting for us */
|
||||
if (thread_group_leader(tsk) &&
|
||||
tsk->signal->notify_count < 0 &&
|
||||
tsk->signal->group_exit_task)
|
||||
tsk->signal->group_exit_task &&
|
||||
tsk->signal->notify_count < 0)
|
||||
wake_up_process(tsk->signal->group_exit_task);
|
||||
|
||||
write_unlock_irq(&tasklist_lock);
|
||||
|
Loading…
Reference in New Issue
Block a user