diff options
author | Jeffrey Wilcke <geffobscura@gmail.com> | 2015-08-03 23:48:24 +0800 |
---|---|---|
committer | Jeffrey Wilcke <geffobscura@gmail.com> | 2015-08-04 00:15:48 +0800 |
commit | dcdb7059cc69ee4e77518b8dd92d5c7037aa3c8d (patch) | |
tree | 6c3e0c5b59ce2ec6515b4ce96d84421b9b635d94 /eth/backend.go | |
parent | e7f4232b10034d291d1757b96e6277908618223c (diff) | |
download | go-tangerine-dcdb7059cc69ee4e77518b8dd92d5c7037aa3c8d.tar go-tangerine-dcdb7059cc69ee4e77518b8dd92d5c7037aa3c8d.tar.gz go-tangerine-dcdb7059cc69ee4e77518b8dd92d5c7037aa3c8d.tar.bz2 go-tangerine-dcdb7059cc69ee4e77518b8dd92d5c7037aa3c8d.tar.lz go-tangerine-dcdb7059cc69ee4e77518b8dd92d5c7037aa3c8d.tar.xz go-tangerine-dcdb7059cc69ee4e77518b8dd92d5c7037aa3c8d.tar.zst go-tangerine-dcdb7059cc69ee4e77518b8dd92d5c7037aa3c8d.zip |
cmd, core, eth: support for the olympic network
Added a --olympic flag which initialiser the olympic protocol settings
Diffstat (limited to 'eth/backend.go')
-rw-r--r-- | eth/backend.go | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/eth/backend.go b/eth/backend.go index bed6231ed..4795000e0 100644 --- a/eth/backend.go +++ b/eth/backend.go @@ -78,6 +78,7 @@ type Config struct { GenesisNonce int GenesisFile string GenesisBlock *types.Block // used by block tests + Olympic bool BlockChainVersion int SkipBcVersionCheck bool // e.g. blockchain export @@ -302,6 +303,14 @@ func New(config *Config) (*Ethereum, error) { glog.V(logger.Info).Infof("Successfully wrote genesis block. New genesis hash = %x\n", block.Hash()) } + if config.Olympic { + _, err := core.WriteTestNetGenesisBlock(stateDb, blockDb, 42) + if err != nil { + return nil, err + } + glog.V(logger.Error).Infoln("Starting Olympic network") + } + // This is for testing only. if config.GenesisBlock != nil { core.WriteBlock(blockDb, config.GenesisBlock) |