mirror of
https://github.com/tendermint/tendermint.git
synced 2026-04-19 15:25:11 +00:00
Lift termination condition into for loop
Signed-off-by: Thane Thomson <connect@thanethomson.com>
This commit is contained in:
@@ -130,11 +130,7 @@ func (*BlockPool) OnStop() {}
|
||||
|
||||
// spawns requesters as needed
|
||||
func (pool *BlockPool) makeRequestersRoutine(ctx context.Context) {
|
||||
for {
|
||||
if !pool.IsRunning() {
|
||||
break
|
||||
}
|
||||
|
||||
for pool.IsRunning() {
|
||||
_, numPending, lenRequesters := pool.GetStatus()
|
||||
switch {
|
||||
case numPending >= maxPendingRequests:
|
||||
|
||||
Reference in New Issue
Block a user