boost库读写锁与互斥锁的用法解析
#include #include #include typedef boost::shared_mutex WR_Mutex;typedef boost::unique_lock writeLock;typedef boost::shared_lock readLock;WR_Mutex lkey;当在用户读一块内存区域时,使用读锁,防止多个线程同时访