Merge pull request #946 from Gustav-Simonsson/fix_geth_unlock_account
Fix hex conversion in --unlock and log when successful
This commit is contained in:
commit
6dec90464d
@ -368,10 +368,11 @@ func unlockAccount(ctx *cli.Context, am *accounts.Manager, account string) (pass
|
|||||||
if len(account) == 0 {
|
if len(account) == 0 {
|
||||||
utils.Fatalf("Invalid account address '%s'", account)
|
utils.Fatalf("Invalid account address '%s'", account)
|
||||||
}
|
}
|
||||||
err = am.Unlock(common.StringToAddress(account), passphrase)
|
err = am.Unlock(common.HexToAddress(account), passphrase)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
utils.Fatalf("Unlock account failed '%v'", err)
|
utils.Fatalf("Unlock account failed '%v'", err)
|
||||||
}
|
}
|
||||||
|
fmt.Printf("Account '%s' unlocked.\n", account)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user