func (pool *BlockPool) Cleanup() {
	for id, peer := range pool.peers {
		peer.Cleanup()
		delete(pool.peers, id)
	}
	pool.plannedRequests = make(map[int64]struct{})
	pool.blocks = make(map[int64]p2p.ID)
	pool.nextRequestHeight = 0
	pool.Height = 0
	pool.MaxPeerHeight = 0
}
// Cleanup performs pool and peer cleanup
Cleanup performs pool and peer cleanup
// Cleanup performs pool and peer cleanup
func (pool *BlockPool) Cleanup() {
	for id, peer := range pool.peers {
		peer.Cleanup()
		delete(pool.peers, id)
	}
	pool.plannedRequests = make(map[int64]struct{})
	pool.blocks = make(map[int64]p2p.ID)
	pool.nextRequestHeight = 0
	pool.Height = 0
	pool.MaxPeerHeight = 0
}
func ( pool * BlockPool ) Cleanup ( ) { for id , peer := range pool . peers { peer . Cleanup ( ) delete ( pool . peers , id ) } pool . plannedRequests = make ( map [ int64 ] struct { } ) pool . blocks = make ( map [ int64 ] p2p . ID ) pool . nextRequestHeight = 0 pool . Height = 0 pool . MaxPeerHeight = 0 }
Cleanup performs pool and peer cleanup
Cleanup performs pool and peer cleanup