From 35d026246c09f0aaa7294a56ee40f1e37292f68d Mon Sep 17 00:00:00 2001 From: Ted Yu Date: Tue, 19 May 2020 19:20:44 -0700 Subject: [PATCH] clientv3: use Mutex for watcher lock Signed-off-by: Ted Yu --- clientv3/watch.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clientv3/watch.go b/clientv3/watch.go index 3612d35f165..7f349eb3988 100644 --- a/clientv3/watch.go +++ b/clientv3/watch.go @@ -139,7 +139,7 @@ type watcher struct { callOpts []grpc.CallOption // mu protects the grpc streams map - mu sync.RWMutex + mu sync.Mutex // streams holds all the active grpc streams keyed by ctx value. streams map[string]*watchGrpcStream