syncer: fix process leak by adding select to state.synced <- false

This commit is contained in:
zelig 2016-05-31 19:42:13 +02:00
parent b610c58875
commit 7925859193

View file

@ -477,7 +477,11 @@ LOOP:
// history channel is closed, waiting for new state (called from sync())
syncStates = self.syncStates
state.Synced = true // this signals that the current segment is complete
state.synced <- false
select {
case state.synced <- false:
case <-self.quit:
break LOOP
}
justSynced = true
history = nil
}