Replace calls to GetHash() with GetTxid() for transaction objects.

Where the caller intends to receive a transaction id and not a double
SHA256 hash.
This commit is contained in:
Simon
2016-07-25 12:23:37 -07:00
parent 1e84d84d3a
commit 10d2c57c0d
32 changed files with 134 additions and 134 deletions

View File

@@ -211,7 +211,7 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn)
unsigned int nTxSize = ::GetSerializeSize(tx, SER_NETWORK, PROTOCOL_VERSION);
dPriority = tx.ComputePriority(dPriority, nTxSize);
uint256 hash = tx.GetHash();
uint256 hash = tx.GetTxid();
mempool.ApplyDeltas(hash, dPriority, nTotalIn);
CFeeRate feeRate(nTotalIn-tx.GetValueOut(), nTxSize);
@@ -255,7 +255,7 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn)
continue;
// Skip free transactions if we're past the minimum block size:
const uint256& hash = tx.GetHash();
const uint256& hash = tx.GetTxid();
double dPriorityDelta = 0;
CAmount nFeeDelta = 0;
mempool.ApplyDeltas(hash, dPriorityDelta, nFeeDelta);
@@ -302,7 +302,7 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn)
if (fPrintPriority)
{
LogPrintf("priority %.1f fee %s txid %s\n",
dPriority, feeRate.ToString(), tx.GetHash().ToString());
dPriority, feeRate.ToString(), tx.GetTxid().ToString());
}
// Add transactions that depend on this one to the priority queue