多线程编程指南

初始化进程内读写锁

#include <thread.h>



rwlock_t rwlp;

int ret;



/* to be used within this process only */

ret = rwlock_init(&rwlp, USYNC_THREAD, 0);