Commit cbd0b420 authored by zelig's avatar zelig

put back checkTD and unskip incorrectTD test

parent f546b486
......@@ -785,10 +785,10 @@ func (self *BlockPool) checkTD(nodes ...*node) {
if n.td != nil {
plog.DebugDetailf("peer td %v =?= block td %v", n.td, n.block.Td)
if n.td.Cmp(n.block.Td) != 0 {
//self.peers.peerError(n.blockBy, ErrIncorrectTD, "on block %x", n.hash)
//self.status.lock.Lock()
//self.status.badPeers[n.blockBy]++
//self.status.lock.Unlock()
self.peers.peerError(n.blockBy, ErrIncorrectTD, "on block %x", n.hash)
self.status.lock.Lock()
self.status.badPeers[n.blockBy]++
self.status.lock.Unlock()
}
}
}
......
......@@ -128,7 +128,7 @@ func TestErrInsufficientChainInfo(t *testing.T) {
}
func TestIncorrectTD(t *testing.T) {
t.Skip() // @zelig this one requires fixing for the TD
// t.Skip() // @zelig this one requires fixing for the TD
test.LogInit()
_, blockPool, blockPoolTester := newTestBlockPool(t)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment