From 68d7682b9f8c0f548e0a9ef03296320b8ae3960d Mon Sep 17 00:00:00 2001 From: Jonas Schnelli Date: Fri, 15 Jul 2016 10:33:25 +0200 Subject: [PATCH] [Wallet] ensure CKeyMetadata.hdMasterKeyID will be cleared during SetNull() --- src/wallet/walletdb.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wallet/walletdb.h b/src/wallet/walletdb.h index eaa406857f2..42179f22887 100644 --- a/src/wallet/walletdb.h +++ b/src/wallet/walletdb.h @@ -87,9 +87,8 @@ public: } CKeyMetadata(int64_t nCreateTime_) { - nVersion = CKeyMetadata::CURRENT_VERSION; + SetNull(); nCreateTime = nCreateTime_; - hdKeypath.clear(); } ADD_SERIALIZE_METHODS; @@ -111,6 +110,7 @@ public: nVersion = CKeyMetadata::CURRENT_VERSION; nCreateTime = 0; hdKeypath.clear(); + hdMasterKeyID.SetNull(); } };