v29.4-roots.3 · Commit 3: [PATCH 03/30] policy: restore conservative relay and network controls
src/net_processing.cpp
Before: src/net_processing.cpp · After: src/net_processing.cpp
File metadata
index 049812763716697b645ba5d4a6bb873e0a4511ae..de81fb24b3225c9422fbf56db9516c5669ca1f14 100644
Download original patch · Release notes
Diff rows 401–417 of 417. Line numbers refer to the original before/after files.
+ Added− RemovedUnmarked lines are context.
Scroll the code area horizontally to read long lines. The two line-number columns refer to before and after.
src/net_processing.cpp
CHANGED
|
@@ -4871,13 +4939,13 @@ bool PeerManagerImpl::MaybeDiscourageAndDisconnect(CNode& pnode, Peer& peer) (continued)
|
|
|
4882
4950
|
}
|
|
4883
4951
|
|
|
@@ -5303,6 +5371,7 @@ void PeerManagerImpl::MaybeSendFeefilter(CNode& pto, Peer& peer, std::chrono::mi
|
|
|
5303
5371
|
{
|
|
5304
5372
|
if (m_opts.ignore_incoming_txs) return;
|
|
5305
5373
|
if (pto.GetCommonVersion() < FEEFILTER_VERSION) return;
|
|
5374
|
+
if (!gArgs.GetBoolArg("-feefilter", DEFAULT_FEEFILTER)) return;
|
|
5306
5375
|
// peers with the forcerelay permission should not filter txs to us
|
|
5307
5376
|
if (pto.HasPermission(NetPermissionFlags::ForceRelay)) return;
|
|
5308
5377
|
// Don't send feefilter messages to outbound block-relay-only peers since they should never announce
|
|
@@ -5648,7 +5717,7 @@ bool PeerManagerImpl::SendMessages(CNode* pto)
|
|
|
5648
5717
|
if (tx_relay->m_next_inv_send_time < current_time) {
|
|
5649
5718
|
fSendTrickle = true;
|
|
5650
5719
|
if (pto->IsInboundConn()) {
|
|
5651
|
-
tx_relay->m_next_inv_send_time = NextInvToInbounds(current_time, INBOUND_INVENTORY_BROADCAST_INTERVAL);
|
|
5720
|
+
tx_relay->m_next_inv_send_time = NextInvToInbounds(current_time, INBOUND_INVENTORY_BROADCAST_INTERVAL, pto->m_network_key);
|
|
5652
5721
|
} else {
|
|
5653
5722
|
tx_relay->m_next_inv_send_time = current_time + m_rng.rand_exp_duration(OUTBOUND_INVENTORY_BROADCAST_INTERVAL);
|
|
5654
5723
|
}
|