MCPcopy
hub / github.com/dropbox/godropbox / RUnlock

Method RUnlock

sync2/boundedrwlock.go:72–79  ·  view source on GitHub ↗

Unlock a read lock. Should be called only on a goroutine which has gotten a non-error return value from RLock().

()

Source from the content-addressed store, hash-verified

70// Should be called only on a goroutine which has gotten a non-error return
71// value from RLock().
72func (rw *BoundedRWLock) RUnlock() {
73 rw.control.Lock()
74 rw.readers--
75 if rw.readers == 0 {
76 rw.processQueue()
77 }
78 rw.control.Unlock()
79}
80
81// Lock for writing, waiting up to 'timeout' for successful exclusive
82// acquisition of the lock.

Callers 4

TestWriterTimeoutMethod · 0.95
TestReaderTimeoutMethod · 0.95
doTestParallelReadersFunction · 0.95
stressRWMutexFunction · 0.95

Calls 3

processQueueMethod · 0.95
LockMethod · 0.65
UnlockMethod · 0.65

Tested by 4

TestWriterTimeoutMethod · 0.76
TestReaderTimeoutMethod · 0.76
doTestParallelReadersFunction · 0.76
stressRWMutexFunction · 0.76