mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
If a new transaction is discovered in the consensus process and we have not
relayed it recently, do so. This is not the perfect solution, it would be better to relay it when we accept the new ledger, relaying only if it fits in the consensus ledger.
This commit is contained in:
@@ -832,6 +832,16 @@ void LedgerConsensus::addDisputedTransaction(const uint256& txID, const std::vec
|
||||
if (cit != mAcquired.end() && cit->second)
|
||||
txn->setVote(pit.first, cit->second->hasItem(txID));
|
||||
}
|
||||
|
||||
if (!ourVote && theApp->isNew(txID))
|
||||
{
|
||||
newcoin::TMTransaction msg;
|
||||
msg.set_rawtransaction(&(tx.front()), tx.size());
|
||||
msg.set_status(newcoin::tsNEW);
|
||||
msg.set_receivetimestamp(theApp->getOPs().getNetworkTimeNC());
|
||||
PackedMessage::pointer packet = boost::make_shared<PackedMessage>(msg, newcoin::mtTRANSACTION);
|
||||
theApp->getConnectionPool().relayMessage(NULL, packet);
|
||||
}
|
||||
}
|
||||
|
||||
bool LedgerConsensus::peerPosition(const LedgerProposal::pointer& newPosition)
|
||||
|
||||
Reference in New Issue
Block a user