small enquiry regarding mutex
instead of using mutex
can i not do the following in the function which the thread calls
pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, NULL);
/* DO WHATEVER YOU WANT TO DO */
pthread_setcancelstate (PTHREAD_CANCEL_ENABLE, NULL);
this way the thread wont get canceled and can perform on a given data. then another thread would start after this thread has finished ??