11 Oct
2006
11 Oct
'06
9:27 p.m.
That said, why do you even have to keep the boost::thread objects? There aren't many useful things that you could do with a boost::thread; if you run 24/7 you should be able to just spawn the threads "detached":
The threads are doing socket stuff, and I want to terminate them gracefully when the application exits (currently they use a shared event that I signal when its time to terminate). I don't like the idea of my application closing while socket threads are still active - I like things to be as clean as possible.
You can replace your version of tss_hooks.cpp with this one:
Thankyou! Just what I was after. FWIW, I think your try_join proposal is an excellent idea.