From e99c788155ddd754c73d2c81b6051dcbd42e6575 Mon Sep 17 00:00:00 2001 From: Péter Szilágyi Date: Sat, 11 Feb 2017 17:02:00 +0200 Subject: accounts: ledger and HD review fixes - Handle a data race where a Ledger drops between list and open - Prolong Ledger tx confirmation window to 30 days from 1 minute - Simplify Ledger chainid-signature calculation and validation - Simplify Ledger USB APDU request chunking algorithm - Silence keystore account cache notifications for manual actions - Only enable self derivations if wallet open succeeds --- cmd/geth/main.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'cmd') diff --git a/cmd/geth/main.go b/cmd/geth/main.go index cc597717e..c19770bfa 100644 --- a/cmd/geth/main.go +++ b/cmd/geth/main.go @@ -273,8 +273,9 @@ func startNode(ctx *cli.Context, stack *node.Node) { for _, wallet := range stack.AccountManager().Wallets() { if err := wallet.Open(""); err != nil { glog.V(logger.Warn).Infof("Failed to open wallet %s: %v", wallet.URL(), err) + } else { + wallet.SelfDerive(accounts.DefaultBaseDerivationPath, stateReader) } - wallet.SelfDerive(accounts.DefaultBaseDerivationPath, stateReader) } // Listen for wallet event till termination for event := range events { @@ -283,8 +284,8 @@ func startNode(ctx *cli.Context, stack *node.Node) { glog.V(logger.Info).Infof("New wallet appeared: %s, failed to open: %s", event.Wallet.URL(), err) } else { glog.V(logger.Info).Infof("New wallet appeared: %s, %s", event.Wallet.URL(), event.Wallet.Status()) + event.Wallet.SelfDerive(accounts.DefaultBaseDerivationPath, stateReader) } - event.Wallet.SelfDerive(accounts.DefaultBaseDerivationPath, stateReader) } else { glog.V(logger.Info).Infof("Old wallet dropped: %s", event.Wallet.URL()) event.Wallet.Close() -- cgit