diff options
author | bojie <bojie@dexon.org> | 2019-01-07 15:40:56 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@dexon.org> | 2019-03-12 12:19:09 +0800 |
commit | 7285c3b0af76e2e470ba3917b006264a06644246 (patch) | |
tree | 97e0e582ff951d5bedddb22cf3f4201e44bbb358 /core/genesis.go | |
parent | f8bd72b9e430960790db8972826a541425b4c552 (diff) | |
download | dexon-7285c3b0af76e2e470ba3917b006264a06644246.tar dexon-7285c3b0af76e2e470ba3917b006264a06644246.tar.gz dexon-7285c3b0af76e2e470ba3917b006264a06644246.tar.bz2 dexon-7285c3b0af76e2e470ba3917b006264a06644246.tar.lz dexon-7285c3b0af76e2e470ba3917b006264a06644246.tar.xz dexon-7285c3b0af76e2e470ba3917b006264a06644246.tar.zst dexon-7285c3b0af76e2e470ba3917b006264a06644246.zip |
app: implement logic for prepare/verify correctly when chain number change (#118)
Diffstat (limited to 'core/genesis.go')
-rw-r--r-- | core/genesis.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/genesis.go b/core/genesis.go index d0875d36d..f07b7a270 100644 --- a/core/genesis.go +++ b/core/genesis.go @@ -170,6 +170,8 @@ func SetupGenesisBlock(db ethdb.Database, genesis *Genesis) (*params.ChainConfig return SetupGenesisBlockWithOverride(db, genesis, nil) } func SetupGenesisBlockWithOverride(db ethdb.Database, genesis *Genesis, constantinopleOverride *big.Int) (*params.ChainConfig, common.Hash, error) { + rawdb.WriteLastRoundNumber(db, 0) + if genesis != nil && genesis.Config == nil { return params.AllEthashProtocolChanges, common.Hash{}, errGenesisNoConfig } |