MCPcopy Create free account
hub / github.com/ElementsProject/lightning / check_probe

Function check_probe

gossipd/seeker.c:782–802  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

780}
781
782static void check_probe(struct seeker *seeker,
783 void (*restart)(struct seeker *seeker))
784{
785 struct peer *peer = seeker->random_peer_softref;
786
787 /* It might have died, pick another. */
788 if (!peer) {
789 restart(seeker);
790 return;
791 }
792
793 /* Is peer making progress with responses? */
794 if (peer_made_progress(seeker))
795 return;
796
797 status_peer_debug(&peer->id,
798 "has only moved gossip %zu->%zu for probe, giving up on it",
799 seeker->prev_gossip_count, peer->gossip_counter);
800 clear_softref(seeker, &seeker->random_peer_softref);
801 restart(seeker);
802}
803
804static bool peer_is_not_gossipper(const struct peer *peer)
805{

Callers 1

seeker_checkFunction · 0.85

Calls 1

peer_made_progressFunction · 0.85

Tested by

no test coverage detected