Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
a5b977aa
Commit
a5b977aa
authored
Jun 09, 2015
by
obscuren
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
core: write accounts to statedb. Closes #1210
parent
0f1cdfa5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
7 deletions
+8
-7
chain_manager.go
core/chain_manager.go
+7
-6
backend.go
eth/backend.go
+1
-1
No files found.
core/chain_manager.go
View file @
a5b977aa
...
...
@@ -111,12 +111,13 @@ type ChainManager struct {
func
NewChainManager
(
genesis
*
types
.
Block
,
blockDb
,
stateDb
common
.
Database
,
pow
pow
.
PoW
,
mux
*
event
.
TypeMux
)
(
*
ChainManager
,
error
)
{
bc
:=
&
ChainManager
{
blockDb
:
blockDb
,
stateDb
:
stateDb
,
eventMux
:
mux
,
quit
:
make
(
chan
struct
{}),
cache
:
NewBlockCache
(
blockCacheLimit
),
pow
:
pow
,
blockDb
:
blockDb
,
stateDb
:
stateDb
,
genesisBlock
:
GenesisBlock
(
42
,
stateDb
),
eventMux
:
mux
,
quit
:
make
(
chan
struct
{}),
cache
:
NewBlockCache
(
blockCacheLimit
),
pow
:
pow
,
}
// Check the genesis block given to the chain manager. If the genesis block mismatches block number 0
...
...
eth/backend.go
View file @
a5b977aa
...
...
@@ -285,7 +285,7 @@ func New(config *Config) (*Ethereum, error) {
}
eth
.
pow
=
ethash
.
New
()
genesis
:=
core
.
GenesisBlock
(
uint64
(
config
.
GenesisNonce
),
block
Db
)
genesis
:=
core
.
GenesisBlock
(
uint64
(
config
.
GenesisNonce
),
state
Db
)
eth
.
chainManager
,
err
=
core
.
NewChainManager
(
genesis
,
blockDb
,
stateDb
,
eth
.
pow
,
eth
.
EventMux
())
if
err
!=
nil
{
return
nil
,
err
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment