[PATCH] fix uninitialized variable in waitid(2)

From: Joe Korty
Date: Thu Dec 02 2004 - 17:43:21 EST


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: Joe Korty <joe.korty@xxxxxxxx>

--- base/kernel/fork.c 2004-12-02 17:18:39.340843441 -0500
+++ new/kernel/fork.c 2004-12-02 17:24:27.085305563 -0500
@@ -733,6 +733,7 @@
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);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/