MCPcopy Create free account
hub / github.com/CPChain/chain / update

Method update

core/blockchain.go:1765–1778  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1763}
1764
1765func (bc *BlockChain) update() {
1766 futureTimer := time.NewTicker(10 * time.Second)
1767 defer futureTimer.Stop()
1768 for {
1769 select {
1770 case <-futureTimer.C:
1771 bc.procFutureBlocks()
1772 bc.procUnknownAncestors()
1773
1774 case <-bc.Quit:
1775 return
1776 }
1777 }
1778}
1779
1780// BadBlocks returns a list of the last 'bad blocks' that the client has seen on the network
1781func (bc *BlockChain) BadBlocks() []*types.Block {

Callers 2

NewBlockChainFunction · 0.95
check_hashFunction · 0.45

Calls 3

procFutureBlocksMethod · 0.95
procUnknownAncestorsMethod · 0.95
StopMethod · 0.65

Tested by

no test coverage detected