diff options
author | accraze <accraze@gmail.com> | 2015-12-11 18:07:11 -0800 |
---|---|---|
committer | accraze <accraze@gmail.com> | 2015-12-11 18:07:11 -0800 |
commit | b6915b82398d2e1d1f888b3816adfaf06d9a450e (patch) | |
tree | 90864192295d859ae449c956835d06e6b97bff0a /src | |
parent | 9ee02cf564d1ce79d2981899cb4d38c914210dc7 (diff) |
checks for null data transaction before debug.log
CWalletTx::GetAmounts could not find output address for null data transactions, thus issuing an error in debug.log. This change checks to see if the transaction is OP_RETURN before issuing error.
resolves #6142
Diffstat (limited to 'src')
-rw-r--r-- | src/wallet/wallet.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp index f3911f314a..a45a9367ad 100644 --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -1034,7 +1034,8 @@ void CWalletTx::GetAmounts(list<COutputEntry>& listReceived, // In either case, we need to get the destination address CTxDestination address; - if (!ExtractDestination(txout.scriptPubKey, address)) + + if (!ExtractDestination(txout.scriptPubKey, address) && txout.scriptPubKey[0] != OP_RETURN) { LogPrintf("CWalletTx::GetAmounts: Unknown transaction type found, txid %s\n", this->GetHash().ToString()); |