Skip to content

Commit cd468d0

Browse files
committed
Define CWallet::DeriveNewChildKey() as private
1 parent ed79e4f commit cd468d0

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/wallet/wallet.h

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,8 @@ class CKeyPool
118118
READWRITE(fInternal);
119119
}
120120
catch (std::ios_base::failure&) {
121-
/* flag as external address if we can't read the internal boolean */
121+
/* flag as external address if we can't read the internal boolean
122+
(this will be the case for any wallet before the HD chain split version) */
122123
fInternal = false;
123124
}
124125
}
@@ -663,6 +664,9 @@ class CWallet : public CCryptoKeyStore, public CValidationInterface
663664
/* the HD chain data model (external chain counters) */
664665
CHDChain hdChain;
665666

667+
/* HD derive new child key (on internal or external chain) */
668+
void DeriveNewChildKey(CKeyMetadata& metadata, CKey& secret, bool internal = false);
669+
666670
bool fFileBacked;
667671

668672
std::set<int64_t> setKeyPool;
@@ -791,7 +795,6 @@ class CWallet : public CCryptoKeyStore, public CValidationInterface
791795
* Generate a new key
792796
*/
793797
CPubKey GenerateNewKey(bool internal = false);
794-
void DeriveNewChildKey(CKeyMetadata& metadata, CKey& secret, bool internal = false);
795798
//! Adds a key to the store, and saves it to disk.
796799
bool AddKeyPubKey(const CKey& key, const CPubKey &pubkey) override;
797800
//! Adds a key to the store, without saving it to disk (used by LoadWallet)

0 commit comments

Comments
 (0)