diff options
author | zsfelfoldi <zsfelfoldi@gmail.com> | 2016-04-05 21:22:04 +0800 |
---|---|---|
committer | zsfelfoldi <zsfelfoldi@gmail.com> | 2016-06-07 22:38:56 +0800 |
commit | f9917c8c7b6d16daadebd72977e56a8adc0382b0 (patch) | |
tree | eb11524c618a44dbd499918761ba176a9addba58 /cmd | |
parent | 5a458da42ae9a6525989c2d4515c6fa573ba8f8c (diff) | |
download | go-tangerine-f9917c8c7b6d16daadebd72977e56a8adc0382b0.tar go-tangerine-f9917c8c7b6d16daadebd72977e56a8adc0382b0.tar.gz go-tangerine-f9917c8c7b6d16daadebd72977e56a8adc0382b0.tar.bz2 go-tangerine-f9917c8c7b6d16daadebd72977e56a8adc0382b0.tar.lz go-tangerine-f9917c8c7b6d16daadebd72977e56a8adc0382b0.tar.xz go-tangerine-f9917c8c7b6d16daadebd72977e56a8adc0382b0.tar.zst go-tangerine-f9917c8c7b6d16daadebd72977e56a8adc0382b0.zip |
core: improved chainDb using sequential keys
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/geth/chaincmd.go | 2 | ||||
-rw-r--r-- | cmd/utils/flags.go | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/cmd/geth/chaincmd.go b/cmd/geth/chaincmd.go index 4f47de5d7..274ad1809 100644 --- a/cmd/geth/chaincmd.go +++ b/cmd/geth/chaincmd.go @@ -170,7 +170,7 @@ func dump(ctx *cli.Context) { for _, arg := range ctx.Args() { var block *types.Block if hashish(arg) { - block = chain.GetBlock(common.HexToHash(arg)) + block = chain.GetBlockByHash(common.HexToHash(arg)) } else { num, _ := strconv.Atoi(arg) block = chain.GetBlockByNumber(uint64(num)) diff --git a/cmd/utils/flags.go b/cmd/utils/flags.go index c476e1c77..6547aae42 100644 --- a/cmd/utils/flags.go +++ b/cmd/utils/flags.go @@ -806,7 +806,7 @@ func MustMakeChainConfig(ctx *cli.Context) *core.ChainConfig { // MustMakeChainConfigFromDb reads the chain configuration from the given database. func MustMakeChainConfigFromDb(ctx *cli.Context, db ethdb.Database) *core.ChainConfig { - genesis := core.GetBlock(db, core.GetCanonicalHash(db, 0)) + genesis := core.GetBlock(db, core.GetCanonicalHash(db, 0), 0) if genesis != nil { // Existing genesis block, use stored config if available. |