mirror of
https://github.com/fluencelabs/tendermint
synced 2025-07-31 20:21:56 +00:00
remove or comment out unused code
This commit is contained in:
@@ -363,23 +363,23 @@ func (pool *BlockPool) sendError(err error, peerID p2p.ID) {
|
||||
pool.errorsCh <- peerError{err, peerID}
|
||||
}
|
||||
|
||||
// unused by tendermint; left for debugging purposes
|
||||
func (pool *BlockPool) debug() string {
|
||||
pool.mtx.Lock()
|
||||
defer pool.mtx.Unlock()
|
||||
// for debugging purposes
|
||||
// func (pool *BlockPool) debug() string {
|
||||
// pool.mtx.Lock()
|
||||
// defer pool.mtx.Unlock()
|
||||
|
||||
str := ""
|
||||
nextHeight := pool.height + pool.requestersLen()
|
||||
for h := pool.height; h < nextHeight; h++ {
|
||||
if pool.requesters[h] == nil {
|
||||
str += fmt.Sprintf("H(%v):X ", h)
|
||||
} else {
|
||||
str += fmt.Sprintf("H(%v):", h)
|
||||
str += fmt.Sprintf("B?(%v) ", pool.requesters[h].block != nil)
|
||||
}
|
||||
}
|
||||
return str
|
||||
}
|
||||
// str := ""
|
||||
// nextHeight := pool.height + pool.requestersLen()
|
||||
// for h := pool.height; h < nextHeight; h++ {
|
||||
// if pool.requesters[h] == nil {
|
||||
// str += fmt.Sprintf("H(%v):X ", h)
|
||||
// } else {
|
||||
// str += fmt.Sprintf("H(%v):", h)
|
||||
// str += fmt.Sprintf("B?(%v) ", pool.requesters[h].block != nil)
|
||||
// }
|
||||
// }
|
||||
// return str
|
||||
// }
|
||||
|
||||
//-------------------------------------
|
||||
|
||||
|
Reference in New Issue
Block a user