diff options
author | BitcoinTsunami <> | 2020-12-11 00:00:43 +0100 |
---|---|---|
committer | BitcoinTsunami <> | 2021-09-28 21:49:35 +0200 |
commit | 240ea294d5e899a906f213f039b21e94c24d6018 (patch) | |
tree | 52533a4cb1156b3dd7a604272d52d144b78114aa /src | |
parent | d6eb39af21810bf1c3bdce0ef2212c1ad6597bcd (diff) | |
download | bitcoin-240ea294d5e899a906f213f039b21e94c24d6018.tar.xz |
doc: update doxygen documention of ComputeTimeSmart() and AddToWalletIfInvolvingMe() regarding rescanning_old_block parameter
Diffstat (limited to 'src')
-rw-r--r-- | src/wallet/wallet.cpp | 2 | ||||
-rw-r--r-- | src/wallet/wallet.h | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp index f0df5016e9..0452474f2f 100644 --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -2384,6 +2384,8 @@ void CWallet::GetKeyBirthTimes(std::map<CKeyID, int64_t>& mapKeyBirth) const { * - If sending a transaction, assign its timestamp to the current time. * - If receiving a transaction outside a block, assign its timestamp to the * current time. + * - If receiving a transaction during a rescanning process, assign all its + * (not already known) transactions' timestamps to the block time. * - If receiving a block with a future timestamp, assign all its (not already * known) transactions' timestamps to the current time. * - If receiving a block with a past timestamp, before the most recent known diff --git a/src/wallet/wallet.h b/src/wallet/wallet.h index 10bac9d5d7..15a5933424 100644 --- a/src/wallet/wallet.h +++ b/src/wallet/wallet.h @@ -271,6 +271,9 @@ private: * abandoned is an indication that it is not safe to be considered abandoned. * Abandoned state should probably be more carefully tracked via different * posInBlock signals or by checking mempool presence when necessary. + * + * Should be called with rescanning_old_block set to true, if the transaction is + * not discovered in real time, but during a rescan of old blocks. */ bool AddToWalletIfInvolvingMe(const CTransactionRef& tx, CWalletTx::Confirmation confirm, bool fUpdate, bool rescanning_old_block) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet); |