This is the mail archive of the
glibc-linux@ricardo.ecn.wfu.edu
mailing list for the glibc project.
Re: linux threads, the manager.
- To: "'Glibc-Linux (E-mail)" <glibc-linux at ricardo dot ecn dot wfu dot edu>
- Subject: Re: linux threads, the manager.
- From: Kaz Kylheku <kaz at ashi dot footprints dot net>
- Date: Tue, 30 Oct 2001 09:29:41 -0800 (PST)
- Reply-To: glibc-linux at ricardo dot ecn dot wfu dot edu
On Tue, 30 Oct 2001, Monserrat Seisdedos Nuņez wrote:
> i have a multithread process under Linux
> i expect every thread in the group to be terminated if i kill one of them.
However, that is just not how things work in Linux, so your
expectation won't be met.
Moreover, there isn't any UNIX or POSIX document which requires the
behavior that you expect.
> PID PPID CMD
> 15744 15509 thr_kill
> 15745 15744 thr_kill
> 15746 15745 thr_kill
> 15747 15745 thr_kill
> 15748 15745 thr_kill
>
> If i kill 15745, i expect every threads to terminate but the result is:
On other systems, you can't even see threads as individual processes
with ps, so you aren't even supposed to be able to do this. It's a
feature of Linux that you can even see threads this way.
> Is any way to avoid it or maybe it is a bug??
If you stick a fork into a toaster, you might get hurt. That is
not a bug in the toaster.