• Andrew Morton's avatar
    [PATCH] de_thread memory corruption fix · 172edfcb
    Andrew Morton authored
    From: Manfred Spraul <manfred@colorfullife.com>
    
    de_thread calls list_del(&current->tasks), but current->tasks was never
    added to the task list. The structure contains stale values from the parent.
    
    switch_exec_pid() transforms a normal thread to a thread group leader.
    Thread group leaders are included in the init_task.tasks linked list,
    non-leaders are not in that list.  The patch adds the new thread group
    leader to the linked list, otherwise de_thread corrupts the task list.
    172edfcb
pid.c 7.44 KB