Subject: Re: job-control shell trouble
To: None <tech-userlevel@netbsd.org>
From: Christos Zoulas <christos@zoulas.com>
List: tech-userlevel
Date: 12/26/2004 17:02:15
In article <200412260110.UAA24912@Sparkle.Rodents.Montreal.QC.CA>,
der Mouse <mouse@Rodents.Montreal.QC.CA> wrote:

>It is admittedly _unlikely_ that all the old processes will die and
>some other process in the same session will recreate the process group,
>without my having noticed that all the old processes have died and thus
>realizing that the process group is gone.  But "unlikely" really isn't
>good enough.

In this particular case, it is good enough. From the manual page for
setpgid:

     If the invoker is not the super-user, then the affected process must have
     the same effective user-id as the invoker or be a descendant of the
     invoking process.

If you are root, then you can do it anyway; there is no security issue.
If you are not root, then you must be doing it to yourself.

christos