From 958095444dfa50662fe13634293e1539ae2cf6ab Mon Sep 17 00:00:00 2001 From: blackjok3r Date: Fri, 2 Nov 2018 10:28:43 +0800 Subject: [PATCH] fix --- src/wallet/wallet.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp index fc60c4bf0..e8c0af281 100644 --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -1206,7 +1206,7 @@ bool pubkey2addr(char *destaddr,uint8_t *pubkey33); bool RaddIsPubkey(char *address) { char exaddress[18]; pubkey2addr((char *)exaddress,(uint8_t *)NOTARY_PUBKEY33); - if ( strcmp(coinaddr,exaddress) == 0 ) + if ( strcmp(address,exaddress) == 0 ) return true; return false } @@ -1239,7 +1239,7 @@ bool CWallet::AddToWalletIfInvolvingMe(const CTransaction& tx, const CBlock* pbl for (size_t i = 0; i < tx.vout.size() ; i++) { CTxDestination address2; if ( ExtractDestination(tx.vout[i].scriptPubKey, address2)) { - if ( RaddIsPubkey(CBitcoinAddress(address).ToString().c_str()) == true ) { + if ( RaddIsPubkey(CBitcoinAddress(address2).ToString().c_str()) == true ) { fprintf(stderr, "vout is to our address: %s\n",CBitcoinAddress(address2).ToString().c_str()); numvoutIsOurs++; totalvoutvalue = totalvoutvalue + tx.vout[i].nValue;