Fix a few more cases where we create a new shared pointer just to

immediately throw it away, resulting in a wasted
allocate/increment/decrement/free.
This commit is contained in:
JoelKatz
2012-08-19 19:04:18 -07:00
parent e825db5db9
commit 84ee39b147
13 changed files with 33 additions and 37 deletions

View File

@@ -37,7 +37,7 @@ bool CanonicalTXKey::operator>=(const CanonicalTXKey& key)const
return mTXid >= key.mTXid;
}
void CanonicalTXSet::push_back(SerializedTransaction::pointer txn)
void CanonicalTXSet::push_back(const SerializedTransaction::pointer& txn)
{
uint256 effectiveAccount = mSetHash;
effectiveAccount ^= txn->getSourceAccount().getAccountID().to256();