Fix possible lock
This commit is contained in:
parent
bec0241d9c
commit
3c3636637e
2
main.go
2
main.go
|
@ -40,8 +40,10 @@ type RealSleeper struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (self RealSleeper) Sleep(ch chan<- interface{}) {
|
func (self RealSleeper) Sleep(ch chan<- interface{}) {
|
||||||
|
go func() {
|
||||||
time.Sleep(self.duration)
|
time.Sleep(self.duration)
|
||||||
ch <- nil
|
ch <- nil
|
||||||
|
}()
|
||||||
}
|
}
|
||||||
|
|
||||||
func getCmdLineParams(logger *log.Logger) (string, []int64) {
|
func getCmdLineParams(logger *log.Logger) (string, []int64) {
|
||||||
|
|
Loading…
Reference in New Issue