Browse Source

agent: simplify a select block

pull/19/head
Armon Dadgar 11 years ago
parent
commit
4f3adcfdda
  1. 2
      command/agent/local.go

2
command/agent/local.go

@ -220,9 +220,7 @@ SYNC:
l.logger.Printf("[ERR] agent: failed to sync remote state: %v", err) l.logger.Printf("[ERR] agent: failed to sync remote state: %v", err)
select { select {
case <-l.consulCh: case <-l.consulCh:
continue
case <-time.After(aeScale(syncRetryIntv, len(l.iface.LANMembers()))): case <-time.After(aeScale(syncRetryIntv, len(l.iface.LANMembers()))):
continue
case <-shutdownCh: case <-shutdownCh:
return return
} }

Loading…
Cancel
Save