Use pthread_cond_t