mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2025-01-18 03:57:34 +00:00
Merge pull request #3736 from nspcc-dev/retry
services: fix defer function in `retry` of NeoFSBlockFetcher
This commit is contained in:
commit
35c2c5cc0e
1 changed files with 4 additions and 1 deletions
|
@ -518,7 +518,10 @@ func (bfs *Service) retry(action func() error) error {
|
|||
)
|
||||
defer func() {
|
||||
if !timer.Stop() {
|
||||
<-timer.C
|
||||
select {
|
||||
case <-timer.C:
|
||||
default:
|
||||
}
|
||||
}
|
||||
}()
|
||||
|
||||
|
|
Loading…
Reference in a new issue