Explorar el Código

fixing deadlock

reid hace 2 años
padre
commit
f29494af53
Se han modificado 1 ficheros con 1 adiciones y 0 borrados
  1. 1 0
      broadcast/broadcast.go

+ 1 - 0
broadcast/broadcast.go

@@ -232,6 +232,7 @@ func GetContainerNetworks(containers []string) map[string]string {
 // update broadcastState with a map of items
 func UpdateBroadcastState(values map[string]interface{}) error {
 	mu.Lock()
+	defer mu.Unlock()
 	v := reflect.ValueOf(&broadcastState).Elem()
 	for key, value := range values {
 		field := v.FieldByName(key)