OR InitFeatures from both Channel and Routing message handlers
authorMatt Corallo <git@bluematt.me>
Wed, 7 Sep 2022 17:35:50 +0000 (17:35 +0000)
committerMatt Corallo <git@bluematt.me>
Fri, 9 Sep 2022 15:36:46 +0000 (15:36 +0000)
commit06cb48afd46c71b10dfd96bdac1c0f509605cf6b
tree63b9083d13cf705f05099f84db10751da8defab5
parent950ccc434046adb8527c9d3c066da482219b924a
OR InitFeatures from both Channel and Routing message handlers

When we go to send an Init message to new peers, the features we
support are really a combination of all the various features our
different handlers support. This commit captures this concept by
OR'ing our InitFeatures across both our Channel and Routing
handlers.

Note that this also disables setting the `initial_routing_sync`
flag in init messages, as was intended in
e742894492c55802b241eebc585bbd28aa16481b, per the comment added on
`clear_initial_routing_sync`, though this should not be a behavior
change in practice as nodes which support gossip queries ignore the
initial routing sync flag.
lightning-net-tokio/src/lib.rs
lightning/src/ln/msgs.rs
lightning/src/ln/peer_handler.rs
lightning/src/routing/gossip.rs
lightning/src/util/test_utils.rs