Commit 9466b9ee authored by Guillaume Ballet's avatar Guillaume Ballet Committed by Péter Szilágyi

signer/core: fix reference issue in key derivation (#19827)

* signer/core: fix reference issue in key derivation

* Review feedback
parent 4ac04ae0
...@@ -479,7 +479,8 @@ func (w *wallet) Derive(path accounts.DerivationPath, pin bool) (accounts.Accoun ...@@ -479,7 +479,8 @@ func (w *wallet) Derive(path accounts.DerivationPath, pin bool) (accounts.Accoun
if _, ok := w.paths[address]; !ok { if _, ok := w.paths[address]; !ok {
w.accounts = append(w.accounts, account) w.accounts = append(w.accounts, account)
w.paths[address] = path w.paths[address] = make(accounts.DerivationPath, len(path))
copy(w.paths[address], path)
} }
return account, nil return account, nil
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment