aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/ethereum
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/ethereum')
-rw-r--r--cmd/ethereum/admin.go7
-rw-r--r--cmd/ethereum/main.go8
2 files changed, 6 insertions, 9 deletions
diff --git a/cmd/ethereum/admin.go b/cmd/ethereum/admin.go
index e71a12392..65adb4086 100644
--- a/cmd/ethereum/admin.go
+++ b/cmd/ethereum/admin.go
@@ -221,13 +221,10 @@ func (js *jsre) exportChain(call otto.FunctionCall) otto.Value {
fmt.Println(err)
return otto.FalseValue()
}
-
- data := js.ethereum.ChainManager().Export()
- if err := common.WriteFile(fn, data); err != nil {
+ if err := utils.ExportChain(js.ethereum.ChainManager(), fn); err != nil {
fmt.Println(err)
return otto.FalseValue()
}
-
return otto.TrueValue()
}
@@ -239,7 +236,7 @@ func (js *jsre) dumpBlock(call otto.FunctionCall) otto.Value {
block = js.ethereum.ChainManager().GetBlockByNumber(uint64(num))
} else if call.Argument(0).IsString() {
hash, _ := call.Argument(0).ToString()
- block = js.ethereum.ChainManager().GetBlock(common.Hex2Bytes(hash))
+ block = js.ethereum.ChainManager().GetBlock(common.HexToHash(hash))
} else {
fmt.Println("invalid argument for dump. Either hex string or number")
}
diff --git a/cmd/ethereum/main.go b/cmd/ethereum/main.go
index 1a662c756..e351453b1 100644
--- a/cmd/ethereum/main.go
+++ b/cmd/ethereum/main.go
@@ -42,7 +42,7 @@ import (
const (
ClientIdentifier = "Ethereum(G)"
- Version = "0.9.1"
+ Version = "0.9.2"
)
var (
@@ -135,7 +135,7 @@ The Ethereum JavaScript VM exposes a node admin interface as well as the DAPP Ja
utils.JSpathFlag,
utils.ListenPortFlag,
utils.LogFileFlag,
- utils.LogFormatFlag,
+ utils.LogJSONFlag,
utils.LogLevelFlag,
utils.MaxPeersFlag,
utils.MinerThreadsFlag,
@@ -251,7 +251,7 @@ func accountList(ctx *cli.Context) {
utils.Fatalf("Could not list accounts: %v", err)
}
for _, acct := range accts {
- fmt.Printf("Address: %#x\n", acct)
+ fmt.Printf("Address: %x\n", acct)
}
}
@@ -314,7 +314,7 @@ func dump(ctx *cli.Context) {
for _, arg := range ctx.Args() {
var block *types.Block
if hashish(arg) {
- block = chainmgr.GetBlock(common.Hex2Bytes(arg))
+ block = chainmgr.GetBlock(common.HexToHash(arg))
} else {
num, _ := strconv.Atoi(arg)
block = chainmgr.GetBlockByNumber(uint64(num))