core: moved TD calculation from proc to chain

This commit is contained in:
obscuren
2015-04-20 12:01:20 +02:00
parent fa729a0c55
commit 97b0c4b697
6 changed files with 24 additions and 24 deletions

View File

@ -93,12 +93,12 @@ func makeChain(bman *BlockProcessor, parent *types.Block, max int, db common.Dat
blocks := make(types.Blocks, max)
for i := 0; i < max; i++ {
block := makeBlock(bman, parent, i, db, seed)
td, _, err := bman.processWithParent(block, parent)
_, err := bman.processWithParent(block, parent)
if err != nil {
fmt.Println("process with parent failed", err)
panic(err)
}
block.Td = td
block.Td = CalculateTD(block, parent)
blocks[i] = block
parent = block
}