Merge pull request #3804

ba51c7d Fix null pointer in IsTrusted() (Cozz Lovan)
This commit is contained in:
Wladimir J. van der Laan 2014-03-05 19:39:34 +01:00
commit f5352da490
No known key found for this signature in database
GPG key ID: 74810B012346C9A6

View file

@ -675,8 +675,10 @@ public:
{
// Transactions not sent by us: not trusted
const CWalletTx* parent = pwallet->GetWalletTx(txin.prevout.hash);
if (parent == NULL)
return false;
const CTxOut& parentOut = parent->vout[txin.prevout.n];
if (parent == NULL || !pwallet->IsMine(parentOut))
if (!pwallet->IsMine(parentOut))
return false;
}
return true;