mirror of
https://github.com/tendermint/tendermint.git
synced 2026-09-19 22:44:24 +00:00
saving development state...
This commit is contained in:
@@ -17,11 +17,11 @@ func NewRepeatTimer(dur time.Duration) *RepeatTimer {
|
||||
var ch = make(chan struct{})
|
||||
var quit = make(chan struct{})
|
||||
var t = &RepeatTimer{Ch: ch, dur: dur, quit: quit}
|
||||
t.timer = time.AfterFunc(dur, t.fireHandler)
|
||||
t.timer = time.AfterFunc(dur, t.fireRoutine)
|
||||
return t
|
||||
}
|
||||
|
||||
func (t *RepeatTimer) fireHandler() {
|
||||
func (t *RepeatTimer) fireRoutine() {
|
||||
select {
|
||||
case t.Ch <- struct{}{}:
|
||||
t.timer.Reset(t.dur)
|
||||
|
||||
Reference in New Issue
Block a user