Avoid reading the old hd master key during wallet encryption#10115
Avoid reading the old hd master key during wallet encryption#10115laanwj merged 1 commit intobitcoin:masterfrom
Conversation
|
utACK fdd15f770a649be57a1c6abc346cd4d0da831493 |
jnewbery
left a comment
There was a problem hiding this comment.
couple of nits, but otherwise utACK fdd15f770a649be57a1c6abc346cd4d0da831493
There was a problem hiding this comment.
nit: remove this unused variable in this commit (it was unused before your PR, but since you're here...)
There was a problem hiding this comment.
suggestion only: combine this with the line above to:
if (!SetHDMasterKey(GenerateNewHDMasterKey()))
Also: curly braces for single line if block please.
There was a problem hiding this comment.
Couple of grammar/typos here. Suggest you replace with: The master key version is set to the current wallet version, so the caller must ensure that current wallet version is correct before calling this function. or similar
fdd15f7 to
e2da46d
Compare
|
Resolved @jnewbery's minor comments. |
There was a problem hiding this comment.
nit: you missed one of the grammar errors: s/keys/key's/ . There's only one of them.
(sorry - normally I wouldn't nit for grammar, but this could be misleading - hence my earlier suggestion to reword)
There was a problem hiding this comment.
Oops, sorry, missed that one
This makes SetHDMasterKey responsible for maintinaing the CHDChain version instead of always creating it with the latest version and making EncryptWallet responsible for keeping the version from changing.
e2da46d to
185c7f0
Compare
|
utACK 185c7f0 |
…ption 185c7f0 Avoid reading the old hd master key during wallet encryption (Matt Corallo) Tree-SHA512: b744e8490c0e948355bb77b2695902bb99f89a68af46aa2be9120bd2ccf3c340eb8a56340fec117f9a935192298028945c9b18120ee6b8b23e7da8ffdb635745
This is a minor clenaup after #9294.
This makes SetHDMasterKey responsible for maintinaing the CHDChain
version instead of always creating it with the latest version and
making EncryptWallet responsible for keeping the version from
changing.