diff options
author | zelig <viktor.tron@gmail.com> | 2015-04-08 19:43:55 +0800 |
---|---|---|
committer | zelig <viktor.tron@gmail.com> | 2015-04-09 20:58:35 +0800 |
commit | 262714fc6c269e0a3aa39892954b03db9418e649 (patch) | |
tree | 0d3ff6490f7df32b09f20c89c5900e0219759fe8 /core/types | |
parent | cbd0b42060d537d4d899b593be1ecd5ffdbd301a (diff) | |
download | go-tangerine-262714fc6c269e0a3aa39892954b03db9418e649.tar go-tangerine-262714fc6c269e0a3aa39892954b03db9418e649.tar.gz go-tangerine-262714fc6c269e0a3aa39892954b03db9418e649.tar.bz2 go-tangerine-262714fc6c269e0a3aa39892954b03db9418e649.tar.lz go-tangerine-262714fc6c269e0a3aa39892954b03db9418e649.tar.xz go-tangerine-262714fc6c269e0a3aa39892954b03db9418e649.tar.zst go-tangerine-262714fc6c269e0a3aa39892954b03db9418e649.zip |
future queued block support
- queued bool // flag for blockpool to skip TD check
- set to true when future block queued
- in checkTD: skip check if queued
- TODO: add test (insertchain sets future block)
Diffstat (limited to 'core/types')
-rw-r--r-- | core/types/block.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/core/types/block.go b/core/types/block.go index 116acbf79..c47b555ed 100644 --- a/core/types/block.go +++ b/core/types/block.go @@ -97,6 +97,7 @@ type Block struct { uncles []*Header transactions Transactions Td *big.Int + queued bool // flag for blockpool to skip TD check receipts Receipts } @@ -268,6 +269,9 @@ func (self *Block) SetNonce(nonce uint64) { self.header.SetNonce(nonce) } +func (self *Block) Queued() bool { return self.queued } +func (self *Block) SetQueued(q bool) { self.queued = q } + func (self *Block) Bloom() Bloom { return self.header.Bloom } func (self *Block) Coinbase() common.Address { return self.header.Coinbase } func (self *Block) Time() int64 { return int64(self.header.Time) } |