Commit 9254615f authored by Linus Torvalds's avatar Linus Torvalds

Make sure we clean user_tid when we've released the

memory space it was associated with.
parent 8edb233c
......@@ -408,12 +408,15 @@ void mm_release(void)
complete(vfork_done);
}
if (tsk->user_tid) {
int * user_tid = tsk->user_tid;
tsk->user_tid = NULL;
/*
* We dont check the error code - if userspace has
* not set up a proper pointer then tough luck.
*/
put_user(0, tsk->user_tid);
sys_futex((unsigned long)tsk->user_tid, FUTEX_WAKE, 1, NULL);
put_user(0, user_tid);
sys_futex((unsigned long)user_tid, FUTEX_WAKE, 1, NULL);
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment