gossipd: advertize all our features in node_announcement.

This preempts the acceptance of
https://github.com/lightningnetwork/lightning-rfc/pull/666 but it's
clear that feature bits are going to be distinct, so this is safe to
do anyway.

See https://github.com/lightningnetwork/lightning-rfc/pull/680

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2019-10-04 10:44:00 +09:30
parent 30ec739c15
commit 33c658ecfb
9 changed files with 28 additions and 8 deletions

View File

@@ -54,6 +54,18 @@ u8 *get_offered_globalfeatures(const tal_t *ctx)
our_globalfeatures, ARRAY_SIZE(our_globalfeatures));
}
/* We currently advertize everything in node_announcement, except
* initial_routing_sync which the spec says not to (and we don't set
* any more anyway).
*
* FIXME: Add bolt ref when finalized!
*/
u8 *get_offered_nodefeatures(const tal_t *ctx)
{
return mkfeatures(ctx,
our_localfeatures, ARRAY_SIZE(our_localfeatures));
}
u8 *get_offered_localfeatures(const tal_t *ctx)
{
return mkfeatures(ctx,