Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix incorrect usage of
timer.Timer
(#45846)
Calling `timer.Stop` in a timer that already fired results in `Stop` returning false and subsequent drain will block because the channel isn't closed. This PR fixes the drain behaviour by wrapping the drain operation in a non-blocking select.
- Loading branch information