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

Function check_probe

gossipd/seeker.c:927–947  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

925}
926
927static void check_probe(struct seeker *seeker,
928 void (*restart)(struct seeker *seeker))
929{
930 struct peer *peer = seeker->random_peer;
931
932 /* It might have died, pick another. */
933 if (!peer) {
934 restart(seeker);
935 return;
936 }
937
938 /* Is peer making progress with responses? */
939 if (peer_made_progress(seeker, peer))
940 return;
941
942 status_peer_debug(&peer->id,
943 "has only moved gossip %zu->%zu for probe, giving up on it",
944 seeker->prev_gossip_count, peer->query_reply_counter);
945 seeker->random_peer = NULL;
946 restart(seeker);
947}
948
949static bool peer_is_not_gossipper(const struct peer *peer)
950{

Callers 1

seeker_checkFunction · 0.85

Calls 1

peer_made_progressFunction · 0.85

Tested by

no test coverage detected