Boost logo

Boost Users :

Subject: Re: [Boost-users] at_thread_exit() never getting called
From: cowwoc (cowwoc_at_[hidden])
Date: 2009-11-08 01:08:57


Peter Dimov-5 wrote:
>
> You can't use an at_thread_exit hook registered from within a thread to
> shut
> down this same thread; this is circular. If you want to shut down a thread
> when exit() is called or when main returns, use atexit, or a destructor of
> a
> static variable. I don't see how at_thread_exit could help in this case,
> although of course I may be misunderstanding something.
>

Part of the problem is that neither atexit() or at_thread_exit() explicitly
specify which thread the hook function will get invoked on...

Gili

-- 
View this message in context: http://old.nabble.com/at_thread_exit%28%29-never-getting-called-tp26053513p26251267.html
Sent from the Boost - Users mailing list archive at Nabble.com.

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net