198 void join() {pthread_join(thread, 0);}
223 bool is_caller() {
return pthread_equal(thread, pthread_self());}
285 #ifdef CGU_USE_AUTO_PTR
293 #ifdef CGU_USE_GLIB_MEMORY_SLICES_NO_COMPAT
390 std::unique_ptr<Cgu::Thread::Thread> thread;
499 #ifdef CGU_USE_AUTO_PTR
552 #ifdef CGU_USE_AUTO_PTR
553 JoinableHandle(std::auto_ptr<Cgu::Thread::Thread> thr,
Action act): action(act), detached(false), thread(thr.release()) {}
555 JoinableHandle(std::unique_ptr<Cgu::Thread::Thread> thr,
Action act): action(act), detached(false), thread(std::move(thr)) {}
587 #ifdef CGU_USE_AUTO_PTR
684 static int block(
int& old_state) {
return pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &old_state);}
712 static int unblock(
int& old_state) {
return pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, &old_state);}
738 int restore(
int& old_state) {
return pthread_setcancelstate(starting_state, &old_state);}