#include "pthread_impl.h" #include void cnd_destroy(cnd_t *cond) { /* Critical section protected by spin lock */ a_splck(&cond->_cx_lock); __cnd_t * ret = cond->_cx_cnd; cond->_cx_cnd = 0; a_spunl(&cond->_cx_lock); if (ret) __cnd_unref(ret); }