mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
Merge pull request #3577 from gyuho/storage/watchable_store.go-defer-fix
storage/watchable_store: defer to Unlock s.mu
This commit is contained in:
commit
d6db4e6d6b
@ -177,7 +177,7 @@ func (s *watchableStore) Watcher(key []byte, prefix bool, startRev, endRev int64
|
||||
|
||||
cancel := CancelFunc(func() {
|
||||
s.mu.Lock()
|
||||
s.mu.Unlock()
|
||||
defer s.mu.Unlock()
|
||||
wa.stopWithError(ErrCanceled)
|
||||
|
||||
// remove global references of the watcher
|
||||
|
Loading…
x
Reference in New Issue
Block a user