From 5ff10c3b65ff3ee1c4d6925b263d6f5cdda0b9e7 Mon Sep 17 00:00:00 2001 From: lyuxuan Date: Thu, 14 Dec 2017 15:42:58 -0800 Subject: [PATCH] fix flaky TestPickfirstOneAddressRemoval (#1731) --- balancer_v1_wrapper.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/balancer_v1_wrapper.go b/balancer_v1_wrapper.go index 6cb39071..76568059 100644 --- a/balancer_v1_wrapper.go +++ b/balancer_v1_wrapper.go @@ -173,10 +173,10 @@ func (bw *balancerWrapper) lbWatcher() { sc.Connect() } } else { - oldSC.UpdateAddresses(newAddrs) bw.mu.Lock() bw.connSt[oldSC].addr = addrs[0] bw.mu.Unlock() + oldSC.UpdateAddresses(newAddrs) } } else { var (