updated genesis

This commit is contained in:
obscuren 2015-03-03 21:09:29 +01:00
parent 26de12d9bf
commit 08fd0715f9
2 changed files with 4 additions and 1 deletions

View File

@ -120,7 +120,6 @@ func Init() {
flag.BoolVar(&StartMining, "mine", false, "start mining") flag.BoolVar(&StartMining, "mine", false, "start mining")
flag.BoolVar(&StartJsConsole, "js", false, "launches javascript console") flag.BoolVar(&StartJsConsole, "js", false, "launches javascript console")
flag.BoolVar(&PrintVersion, "version", false, "prints version number") flag.BoolVar(&PrintVersion, "version", false, "prints version number")
flag.IntVar(&MinerThreads, "minerthreads", runtime.NumCPU(), "number of miner threads")
// Network stuff // Network stuff
var ( var (

View File

@ -28,6 +28,9 @@ func GenesisBlock(db ethutil.Database) *types.Block {
genesis.Header().GasLimit = big.NewInt(1000000) genesis.Header().GasLimit = big.NewInt(1000000)
genesis.Header().GasUsed = ethutil.Big0 genesis.Header().GasUsed = ethutil.Big0
genesis.Header().Time = 0 genesis.Header().Time = 0
genesis.Header().MixDigest = make([]byte, 32)
genesis.Header().SeedHash = make([]byte, 32)
genesis.Td = ethutil.Big0 genesis.Td = ethutil.Big0
genesis.SetUncles([]*types.Header{}) genesis.SetUncles([]*types.Header{})
@ -50,6 +53,7 @@ func GenesisBlock(db ethutil.Database) *types.Block {
} }
statedb.Sync() statedb.Sync()
genesis.Header().Root = statedb.Root() genesis.Header().Root = statedb.Root()
fmt.Println(genesis)
return genesis return genesis
} }