Commit ac7e5c71 authored by Joe Korty's avatar Joe Korty Committed by Linus Torvalds

[PATCH] fix uninitialized variable in waitid(2)

Specify an initial value signal_struct's field stop_state whenever a
signal_struct variable is created.

Bug was discovered through the occasional failure of telnet(1) to connect.
Signed-off-by: default avatarJoe Korty <joe.korty@ccur.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent e681089e
......@@ -733,6 +733,7 @@ static inline int copy_signal(unsigned long clone_flags, struct task_struct * ts
sig->group_exit_code = 0;
sig->group_exit_task = NULL;
sig->group_stop_count = 0;
sig->stop_state = 0;
sig->curr_target = NULL;
init_sigpending(&sig->shared_pending);
INIT_LIST_HEAD(&sig->posix_timers);
......
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