mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-12 06:58:57 +01:00
Move recently introduced CTransAction::IsEquivalentTo to CWalletTx
CTransAction::IsEquivalentTo was introduced in #5881. This functionality is only useful to the wallet, and should never have been added to the primitive transaction type.
This commit is contained in:
@@ -1331,6 +1331,15 @@ bool CWalletTx::IsTrusted() const
|
||||
return true;
|
||||
}
|
||||
|
||||
bool CWalletTx::IsEquivalentTo(const CWalletTx& tx) const
|
||||
{
|
||||
CMutableTransaction tx1 = *this;
|
||||
CMutableTransaction tx2 = tx;
|
||||
for (unsigned int i = 0; i < tx1.vin.size(); i++) tx1.vin[i].scriptSig = CScript();
|
||||
for (unsigned int i = 0; i < tx2.vin.size(); i++) tx2.vin[i].scriptSig = CScript();
|
||||
return CTransaction(tx1) == CTransaction(tx2);
|
||||
}
|
||||
|
||||
std::vector<uint256> CWallet::ResendWalletTransactionsBefore(int64_t nTime)
|
||||
{
|
||||
std::vector<uint256> result;
|
||||
|
||||
Reference in New Issue
Block a user