Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Pagghiu/SaneCppLibraries
/ unlockRead
Method
unlockRead
Libraries/Threading/Threading.cpp:68–77 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
66
}
67
activeReaders++;
68
mutex.unlock();
69
}
70
71
void SC::RWLock::unlockRead()
72
{
73
mutex.lock();
74
activeReaders--;
75
if (activeReaders == 0 && waitingWriters > 0)
76
{
77
writersQ.signal();
78
}
79
mutex.unlock();
80
}
Callers
1
testRWLock
Method · 0.80
Calls
3
lock
Method · 0.45
signal
Method · 0.45
unlock
Method · 0.45
Tested by
1
testRWLock
Method · 0.64