merge bitcoin#22618: Small follow-ups to 21528

This commit is contained in:
Kittywhiskers Van Gogh 2021-08-03 09:25:38 -07:00
parent 18fe765988
commit 8b8fbc5226
No known key found for this signature in database
GPG Key ID: 30CD0C065E5C4AAD
3 changed files with 11 additions and 2 deletions

View File

@ -6,3 +6,10 @@ RPC changes
- `getnodeaddresses` now also accepts a "network" argument (ipv4, ipv6, onion,
or i2p) to return only addresses of the specified network.
P2P and network changes
-----------------------
- A dashd node will no longer rumour addresses to inbound peers by default.
They will become eligible for address gossip after sending an ADDR, ADDRV2,
or GETADDR message.

View File

@ -4397,7 +4397,9 @@ void PeerManagerImpl::ProcessMessage(
return;
}
SetupAddressRelay(pfrom, *peer);
// Since this must be an inbound connection, SetupAddressRelay will
// never fail.
Assume(SetupAddressRelay(pfrom, *peer));
// Only send one GetAddr response per connection to reduce resource waste
// and discourage addr stamping of INV announcements.

View File

@ -175,7 +175,7 @@ class AddrTest(BitcoinTestFramework):
# of the outbound peer which is often sent before the GETADDR response.
assert_equal(inbound_peer.num_ipv4_received, 0)
# Send an empty ADDR message to intialize address relay on this connection.
# Send an empty ADDR message to initialize address relay on this connection.
inbound_peer.send_and_ping(msg_addr())
self.log.info('Check that subsequent addr messages sent from an outbound peer are relayed')