From 3854be0e50494ce64338ce89e08e64e8730c1855 Mon Sep 17 00:00:00 2001 From: Arik Sosman Date: Fri, 15 Nov 2024 12:32:38 -0800 Subject: [PATCH] Trigger full sync on old GossipTimestampFilter --- lightning/src/ln/peer_handler.rs | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/lightning/src/ln/peer_handler.rs b/lightning/src/ln/peer_handler.rs index 96a5df3b464..d805db0f1da 100644 --- a/lightning/src/ln/peer_handler.rs +++ b/lightning/src/ln/peer_handler.rs @@ -1721,11 +1721,24 @@ impl 1970").as_secs() - 3600; + } + if peer_lock.their_features.as_ref().unwrap().supports_gossip_queries() && - !peer_lock.sent_gossip_timestamp_filter { + !peer_lock.sent_gossip_timestamp_filter && + (msg.first_timestamp as u64) <= full_sync_threshold + { peer_lock.sent_gossip_timestamp_filter = true; peer_lock.sync_status = InitSyncTracker::ChannelsSyncing(0); }