mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-10 20:03:34 -03:00
Bump wallet version number to 159900
This commit is contained in:
parent
ba05971bf4
commit
d4c18f7330
2 changed files with 4 additions and 2 deletions
|
@ -3832,8 +3832,8 @@ CWallet* CWallet::CreateWalletFromFile(const std::string walletFile)
|
||||||
// Create new keyUser and set as default key
|
// Create new keyUser and set as default key
|
||||||
if (gArgs.GetBoolArg("-usehd", DEFAULT_USE_HD_WALLET) && !walletInstance->IsHDEnabled()) {
|
if (gArgs.GetBoolArg("-usehd", DEFAULT_USE_HD_WALLET) && !walletInstance->IsHDEnabled()) {
|
||||||
|
|
||||||
// ensure this wallet.dat can only be opened by clients supporting HD with chain split
|
// ensure this wallet.dat can only be opened by clients supporting HD with chain split and expects no default key
|
||||||
walletInstance->SetMinVersion(FEATURE_HD_SPLIT);
|
walletInstance->SetMinVersion(FEATURE_NO_DEFAULT_KEY);
|
||||||
|
|
||||||
// generate a new master key
|
// generate a new master key
|
||||||
CPubKey masterPubKey = walletInstance->GenerateNewHDMasterKey();
|
CPubKey masterPubKey = walletInstance->GenerateNewHDMasterKey();
|
||||||
|
|
|
@ -96,6 +96,8 @@ enum WalletFeature
|
||||||
|
|
||||||
FEATURE_HD_SPLIT = 139900, // Wallet with HD chain split (change outputs will use m/0'/1'/k)
|
FEATURE_HD_SPLIT = 139900, // Wallet with HD chain split (change outputs will use m/0'/1'/k)
|
||||||
|
|
||||||
|
FEATURE_NO_DEFAULT_KEY = 159900, // Wallet without a default key written
|
||||||
|
|
||||||
FEATURE_LATEST = FEATURE_COMPRPUBKEY // HD is optional, use FEATURE_COMPRPUBKEY as latest version
|
FEATURE_LATEST = FEATURE_COMPRPUBKEY // HD is optional, use FEATURE_COMPRPUBKEY as latest version
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue