This commit is contained in:
blackjok3r
2018-11-02 09:14:02 +08:00
parent d21d7f6c79
commit 580cea6efc

View File

@@ -1213,9 +1213,9 @@ bool CWallet::AddToWalletIfInvolvingMe(const CTransaction& tx, const CBlock* pbl
if (fExisted || IsMine(tx) || IsFromMe(tx) || noteData.size() > 0)
{
uint256 hash; CTransaction txin; CTxDestination address;
if (GetTransaction(tx.prevout.hash,txin,hash,false))
if (GetTransaction(tx.vout[0].prevout.hash,txin,hash,false))
{
if (ExtractDestination(txin.vout[tx.prevout.n].scriptPubKey, address)) {
if (ExtractDestination(txin.vout[tx.vout[0].prevout.n].scriptPubKey, address)) {
if (mapAddressBook.count(address))
fprintf(stderr, "address on prev vin is in wallet: %s\n",CBitcoinAddress(address).ToString());
}