From bcd2301b811f2d1a6cca7349a44d3a8a35ab95ec Mon Sep 17 00:00:00 2001 From: Frank Schroeder Date: Fri, 30 Jun 2017 13:44:07 +0200 Subject: [PATCH] agent: fix data race in TestAgentAntiEntropy_EnableTagOverride --- agent/local_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/agent/local_test.go b/agent/local_test.go index 4c80540472..5f5e19bfdf 100644 --- a/agent/local_test.go +++ b/agent/local_test.go @@ -312,6 +312,9 @@ func TestAgentAntiEntropy_EnableTagOverride(t *testing.T) { r.Fatalf("err: %v", err) } + a.state.RLock() + defer a.state.RUnlock() + // All the services should match for id, serv := range services.NodeServices.Services { serv.CreateIndex, serv.ModifyIndex = 0, 0