Page MenuHomePhabricator

[net processing] Refactor MaybeSendAddr() - early exits
ClosedPublic

Authored by PiRK on Jan 27 2022, 16:16.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC4521689ee985: [net processing] Refactor MaybeSendAddr() - early exits
Summary

Add early exit guard clauses if node.RelayAddrsWithConn() is false or if
current_time < node.m_next_addr_send. Add comments.

This is a backport of core#21236 [5/6]
https://github.com/bitcoin/bitcoin/pull/21236/commits/38c0be5da3af17208b165e73cee7612d3670b038
https://github.com/bitcoin/bitcoin/pull/21236/commits/01a79ff924b11f91796d4aa63c571897b047ac7d

Depends on D10918

Test Plan

ninja all check-all

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable