mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-02-09 10:43:19 -05:00
Fix null pointer in IsTrusted()
This commit is contained in:
parent
334bd22e75
commit
ba51c7da40
1 changed files with 3 additions and 1 deletions
|
@ -675,8 +675,10 @@ public:
|
||||||
{
|
{
|
||||||
// Transactions not sent by us: not trusted
|
// Transactions not sent by us: not trusted
|
||||||
const CWalletTx* parent = pwallet->GetWalletTx(txin.prevout.hash);
|
const CWalletTx* parent = pwallet->GetWalletTx(txin.prevout.hash);
|
||||||
|
if (parent == NULL)
|
||||||
|
return false;
|
||||||
const CTxOut& parentOut = parent->vout[txin.prevout.n];
|
const CTxOut& parentOut = parent->vout[txin.prevout.n];
|
||||||
if (parent == NULL || !pwallet->IsMine(parentOut))
|
if (!pwallet->IsMine(parentOut))
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Add table
Reference in a new issue