aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Chow <achow101-github@achow101.com>2020-05-22 13:42:35 -0400
committerAndrew Chow <achow101-github@achow101.com>2020-06-15 10:58:31 -0400
commit3a03a11e8c696e2164b8bb221a4a35a7c3ac4d6d (patch)
tree73d5d165c2ec75219a930ac7fa1287367bc674c3
parentb5c423c48e094bd098e11c3d1f57acae7502a4da (diff)
Skip hdKeypath of 'm'
Previously the seed was stored with keypath 'm' so we need to skip this as well when determining inactive seeds.
-rw-r--r--src/wallet/walletdb.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/wallet/walletdb.cpp b/src/wallet/walletdb.cpp
index 331408ef48..23993a3a53 100644
--- a/src/wallet/walletdb.cpp
+++ b/src/wallet/walletdb.cpp
@@ -441,10 +441,11 @@ ReadKeyValue(CWallet* pwallet, CDataStream& ssKey, CDataStream& ssValue,
// Extract some CHDChain info from this metadata if it has any
if (keyMeta.nVersion >= CKeyMetadata::VERSION_WITH_HDDATA && !keyMeta.hd_seed_id.IsNull() && keyMeta.hdKeypath.size() > 0) {
// Get the path from the key origin or from the path string
- // Not applicable when path is "s" as that indicates a seed
+ // Not applicable when path is "s" or "m" as those indicate a seed
+ // See https://github.com/bitcoin/bitcoin/pull/12924
bool internal = false;
uint32_t index = 0;
- if (keyMeta.hdKeypath != "s") {
+ if (keyMeta.hdKeypath != "s" && keyMeta.hdKeypath != "m") {
std::vector<uint32_t> path;
if (keyMeta.has_key_origin) {
// We have a key origin, so pull it from its path vector