Revert "ae: make control flow more explicit"

This reverts commit b9a8b53d52.
This commit is contained in:
Frank Schroeder 2017-10-23 10:08:32 +02:00
parent 65166cce8e
commit 25ed78c8f7
No known key found for this signature in database
GPG Key ID: 4D65C6EAEC87DECD
1 changed files with 2 additions and 2 deletions

View File

@ -142,7 +142,6 @@ FullSync:
case <-s.SyncFull.Notif(): case <-s.SyncFull.Notif():
select { select {
case <-time.After(s.stagger(s.serverUpInterval)): case <-time.After(s.stagger(s.serverUpInterval)):
continue FullSync
case <-s.ShutdownCh: case <-s.ShutdownCh:
return return
} }
@ -150,11 +149,12 @@ FullSync:
// retry full sync after some time // retry full sync after some time
// todo(fs): why don't we use s.Interval here? // todo(fs): why don't we use s.Interval here?
case <-time.After(s.retryFailInterval + s.stagger(s.retryFailInterval)): case <-time.After(s.retryFailInterval + s.stagger(s.retryFailInterval)):
continue FullSync
case <-s.ShutdownCh: case <-s.ShutdownCh:
return return
} }
continue
} }
// do partial syncs until it is time for a full sync again // do partial syncs until it is time for a full sync again