View Full Version : pthread's - check for running thread

05-29-2005, 11:52 AM
To create a thread one uses pthread_create. To terminate it, pthread_cancel, to wait for it's termination pthread_join... but how do we check if a thread has exit, (or not) by it's id, without blocking on the function's call ?
In windows it would be WaitForSignleObject(thread_handle,0)

05-29-2005, 02:15 PM
How to determine if thread has died having its pthread_t tid? (http://groups-beta.google.com/group/comp.programming.threads/browse_frm/thread/35299fc77ea1a447)


05-29-2005, 03:32 PM
the cleanup stuff gave me a good ideia.. instead of calling the thread function, I'll call my own function which calls the thread function. And mine will then signal a var.
Thank you