mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-24 01:24:26 +01:00
gossip: Use the custom gossip wire msg to wrap channel_announcements
This stores and reads the channel_announcements in the wrapping message which allows us to store associated data with the raw channel_announcements. The gossip_store applies channel_announcements directly but it also returns it, and it gets discarded as a duplicate. In the next commit we'll have gossip_store apply all changes, bypassing verification, so the duplication is only temporary. Signed-off-by: Christian Decker <decker.christian@gmail.com>
This commit is contained in:
committed by
Rusty Russell
parent
6894f20927
commit
6e01f38d7d
@@ -833,7 +833,7 @@ bool handle_pending_cannouncement(struct routing_state *rstate,
|
||||
}
|
||||
|
||||
if (pending->store)
|
||||
gossip_store_append(rstate->store, pending->announce);
|
||||
gossip_store_add_channel_announcement(rstate->store, pending->announce, satoshis);
|
||||
routing_add_channel_announcement(rstate, pending->announce, satoshis);
|
||||
|
||||
local = pubkey_eq(&pending->node_id_1, &rstate->local_id) ||
|
||||
|
||||
Reference in New Issue
Block a user