aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet.cpp
diff options
context:
space:
mode:
authorpracticalswift <practicalswift@users.noreply.github.com>2017-08-28 09:24:17 +0200
committerpracticalswift <practicalswift@users.noreply.github.com>2017-09-06 10:45:37 +0200
commitfdc329376c8a0fa4dffd0cd2599a494a64c38472 (patch)
tree2e2052bb1fced6b82e6eb58adb64c7c9bf23fcf8 /src/wallet/wallet.cpp
parent6866b4912b8013ed748d12250209f7079a3c92e6 (diff)
Document assumptions that are being made to avoid NULL pointer dereferences
Diffstat (limited to 'src/wallet/wallet.cpp')
-rw-r--r--src/wallet/wallet.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp
index d1d2060b0c..36d6ce0007 100644
--- a/src/wallet/wallet.cpp
+++ b/src/wallet/wallet.cpp
@@ -519,6 +519,7 @@ void CWallet::SyncMetaData(std::pair<TxSpends::iterator, TxSpends::iterator> ran
const uint256& hash = it->second;
CWalletTx* copyTo = &mapWallet[hash];
if (copyFrom == copyTo) continue;
+ assert(copyFrom && "Oldest wallet transaction in range assumed to have been found.");
if (!copyFrom->IsEquivalentTo(*copyTo)) continue;
copyTo->mapValue = copyFrom->mapValue;
copyTo->vOrderForm = copyFrom->vOrderForm;