Add HD keypath to CKeyMetadata, report metadata in validateaddress

https://github.com/bitcoin/bitcoin/pull/8323
This commit is contained in:
lateminer
2018-01-02 14:30:26 +03:00
parent 0e02c74800
commit b741b11cad
5 changed files with 25 additions and 7 deletions

View File

@@ -2310,7 +2310,7 @@ UniValue getwalletinfo(const UniValue& params, bool fHelp)
" \"keypoolsize\": xxxx, (numeric) how many new keys are pre-generated\n"
" \"unlocked_until\": ttt, (numeric) the timestamp in seconds since epoch (midnight Jan 1 1970 GMT) that the wallet is unlocked for transfers, or 0 if the wallet is locked\n"
" \"paytxfee\": x.xxxx, (numeric) the transaction fee configuration, set in " + CURRENCY_UNIT + "/kB\n"
" \"hdmasterkeyid\": \"<hash160>\", (string) the Hash160 of the hd master pubkey\n"
" \"hdmasterkeyid\": \"<hash160>\", (string) the Hash160 of the HD master pubkey\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getwalletinfo", "")
@@ -2332,7 +2332,7 @@ UniValue getwalletinfo(const UniValue& params, bool fHelp)
obj.push_back(Pair("paytxfee", ValueFromAmount(payTxFee.GetFeePerK())));
CKeyID masterKeyID = pwalletMain->GetHDChain().masterKeyID;
if (!masterKeyID.IsNull())
obj.push_back(Pair("hdmasterkeyid",masterKeyID.GetHex()));
obj.push_back(Pair("hdmasterkeyid", masterKeyID.GetHex()));
return obj;
}