This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: TSD destructors not being called for initialthread
- From: Kaz Kylheku <kaz at ashi dot footprints dot net>
- To: Boris Kolpackov <boris at kolpackov dot net>
- Cc: Ulrich Drepper <drepper at redhat dot com>, <libc-alpha at sources dot redhat dot com>
- Date: Wed, 31 Mar 2004 11:41:58 -0800 (PST)
- Subject: Re: TSD destructors not being called for initialthread
On Wed, 31 Mar 2004, Boris Kolpackov wrote:
> Date: Wed, 31 Mar 2004 13:40:22 -0600
> From: Boris Kolpackov <boris@kolpackov.net>
> To: Ulrich Drepper <drepper@redhat.com>
> Cc: libc-alpha@sources.redhat.com
> Subject: [libc-alpha] Re: TSD destructors not being called for initial
> thread
>
> Hi Ulrich,
>
> > That's fixed in the CVS version.
>
> Looking at your fix I still think TSD destructors are not called
> if initial thread returns from main (as opposed to being canceled
> or via pthread_exit ()).
That is a case of process termination. Process termination blows
away threads. If you have any other threads beside the initial one,
and those threads have associated TSD, they will be stopped dead in
their tracks without any opportunity to execute destructors. So why
should the main thread's destructors be executed?
--
Meta-CVS: the working replacement for CVS that has been stable for two
years. It versions the directory structure, symbolic links and execute
permissions. It figures out renaming on import. Plus it babysits the kids
and does light housekeeping! http://freshmeat.net/projects/mcvs