diff options
author | Oleg Nesterov <oleg@tv-sign.ru> | 2008-02-08 07:19:12 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-08 12:22:27 -0500 |
commit | 6806aac6d282d58b97763f5e17e2787e62c3b440 (patch) | |
tree | 4076069a60e054a2d8c31bc2998607668b0a40b0 | |
parent | d12619b5ff5664623524aef796514d1946ea3b4a (diff) |
sys_setsid: remove now unneeded session != 1 check
Eric's "fix clone(CLONE_NEWPID)" eliminated the last reason for this hack.
Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Roland McGrath <roland@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | kernel/sys.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/kernel/sys.c b/kernel/sys.c index 7de9c984f696..ee2e78dbea6c 100644 --- a/kernel/sys.c +++ b/kernel/sys.c | |||
@@ -1056,11 +1056,8 @@ asmlinkage long sys_setsid(void) | |||
1056 | 1056 | ||
1057 | /* Fail if a process group id already exists that equals the | 1057 | /* Fail if a process group id already exists that equals the |
1058 | * proposed session id. | 1058 | * proposed session id. |
1059 | * | ||
1060 | * Don't check if session == 1, clone(CLONE_NEWPID) creates | ||
1061 | * this group/session beforehand. | ||
1062 | */ | 1059 | */ |
1063 | if (session != 1 && pid_task(sid, PIDTYPE_PGID)) | 1060 | if (pid_task(sid, PIDTYPE_PGID)) |
1064 | goto out; | 1061 | goto out; |
1065 | 1062 | ||
1066 | group_leader->signal->leader = 1; | 1063 | group_leader->signal->leader = 1; |