aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/exit.c
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2007-03-29 01:38:16 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-03-29 11:16:23 -0400
commit14e9d5730adfca26452b3a2838a80af6950556f5 (patch)
tree2288e59261478c013935cfe99e6565057e525452 /kernel/exit.c
parentc97beb4710bc673867207d7d729f2ace4ca1f197 (diff)
[PATCH] pid: Properly detect orphaned process groups in exit_notify
In commit 0475ac0845f9295bc5f69af45f58dff2c104c8d1 when converting the orphaned process group handling to use struct pid I made a small mistake. I accidentally replaced an == with a !=. Besides just being a dumb thing to do apparently this has a bad side effect. The improper orphaned process group detection causes kwin to die after a suspend/resume cycle. I'm amazed this patch has been around as long as it has without anyone else noticing something funny going on. And the following people deserve credit for spotting and helping to reproduce this. Thanks to: Sid Boyce <g3vbv@blueyonder.co.uk> Thanks to: "Michael Wu" Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/exit.c')
-rw-r--r--kernel/exit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/exit.c b/kernel/exit.c
index f132349c0325..b55ed4cc9104 100644
--- a/kernel/exit.c
+++ b/kernel/exit.c
@@ -790,7 +790,7 @@ static void exit_notify(struct task_struct *tsk)
790 790
791 pgrp = task_pgrp(tsk); 791 pgrp = task_pgrp(tsk);
792 if ((task_pgrp(t) != pgrp) && 792 if ((task_pgrp(t) != pgrp) &&
793 (task_session(t) != task_session(tsk)) && 793 (task_session(t) == task_session(tsk)) &&
794 will_become_orphaned_pgrp(pgrp, tsk) && 794 will_become_orphaned_pgrp(pgrp, tsk) &&
795 has_stopped_jobs(pgrp)) { 795 has_stopped_jobs(pgrp)) {
796 __kill_pgrp_info(SIGHUP, SEND_SIG_PRIV, pgrp); 796 __kill_pgrp_info(SIGHUP, SEND_SIG_PRIV, pgrp);