]> git.hungrycats.org Git - linux/commitdiff
alpha pid-reporting POSIX comformance bug fix:
authorJeff Garzik <jgarzik@mandrakesoft.com>
Wed, 31 Jul 2002 07:17:02 +0000 (03:17 -0400)
committerJeff Garzik <jgarzik@mandrakesoft.com>
Wed, 31 Jul 2002 07:17:02 +0000 (03:17 -0400)
2.4 kernels were changed to support POSIX thread groups, such that,
sys_getpid() now returns $task->tgid, the thread group id.

Since alpha implements its own getpid syscall, it missed this change,
which is now included here.

arch/alpha/kernel/osf_sys.c

index dd9af1ed207ac93c6e6d25797fe543c2d84210c5..9dd48b15441c8599bf5077880009de938b432b31 100644 (file)
@@ -221,8 +221,8 @@ asmlinkage unsigned long sys_getxpid(int a0, int a1, int a2, int a3, int a4,
         * isn't actually going to matter, as if the parent happens
         * to change we can happily return either of the pids.
         */
-       (&regs)->r20 = tsk->real_parent->pid;
-       return tsk->pid;
+       (&regs)->r20 = tsk->real_parent->tgid;
+       return tsk->tgid;
 }
 
 asmlinkage unsigned long osf_mmap(unsigned long addr, unsigned long len,