Re: Broken su in current - trying to fix myself, help needed!

From: Andrey Chernov <ache_at_nagual.pp.ru>
Date: Wed, 17 Oct 2007 22:41:05 +0400
On Wed, Oct 17, 2007 at 10:32:16PM +0400, Artem Kuchin wrote:
> There are such like in the default: dection of switch
> 
>                child_pgrp = getpgid(child_pid);
>                if (tcgetpgrp(STDERR_FILENO) == child_pgrp)
>                        tcsetpgrp(STDERR_FILENO, getpgrp());
> 
> 
> The problem is here.
> getpgid(child_pid) simply fails with errno 3 (process doesn't exist)

The question is: why getpgid() fails while process really exists (in 
stopped state)?

-- 
http://ache.pp.ru/
Received on Wed Oct 17 2007 - 16:41:08 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:19 UTC