@@ -902,15 +902,15 @@ static bool CompareNodeTXTime(const NodeEvictionCandidate &a, const NodeEviction
902902{
903903 // There is a fall-through here because it is common for a node to have more than a few peers that have not yet relayed txn.
904904 if (a.m_last_tx_time != b.m_last_tx_time ) return a.m_last_tx_time < b.m_last_tx_time ;
905- if (a.fRelayTxes != b.fRelayTxes ) return b.fRelayTxes ;
905+ if (a.m_relay_txs != b.m_relay_txs ) return b.m_relay_txs ;
906906 if (a.fBloomFilter != b.fBloomFilter ) return a.fBloomFilter ;
907907 return a.m_connected > b.m_connected ;
908908}
909909
910910// Pick out the potential block-relay only peers, and sort them by last block time.
911911static bool CompareNodeBlockRelayOnlyTime (const NodeEvictionCandidate &a, const NodeEvictionCandidate &b)
912912{
913- if (a.fRelayTxes != b.fRelayTxes ) return a.fRelayTxes ;
913+ if (a.m_relay_txs != b.m_relay_txs ) return a.m_relay_txs ;
914914 if (a.m_last_block_time != b.m_last_block_time ) return a.m_last_block_time < b.m_last_block_time ;
915915 if (a.fRelevantServices != b.fRelevantServices ) return b.fRelevantServices ;
916916 return a.m_connected > b.m_connected ;
@@ -1035,7 +1035,7 @@ void ProtectEvictionCandidatesByRatio(std::vector<NodeEvictionCandidate>& evicti
10351035 EraseLastKElements (vEvictionCandidates, CompareNodeTXTime, 4 );
10361036 // Protect up to 8 non-tx-relay peers that have sent us novel blocks.
10371037 EraseLastKElements (vEvictionCandidates, CompareNodeBlockRelayOnlyTime, 8 ,
1038- [](const NodeEvictionCandidate& n) { return !n.fRelayTxes && n.fRelevantServices ; });
1038+ [](const NodeEvictionCandidate& n) { return !n.m_relay_txs && n.fRelevantServices ; });
10391039
10401040 // Protect 4 nodes that most recently sent us novel blocks.
10411041 // An attacker cannot manipulate this metric without performing useful work.
0 commit comments