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

Function connectd_peer_gone

gossipd/gossipd.c:431–447  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

429}
430
431static void connectd_peer_gone(struct daemon *daemon, const u8 *msg)
432{
433 struct node_id id;
434 struct peer *peer;
435
436 if (!fromwire_gossipd_peer_gone(msg, &id)) {
437 status_failed(STATUS_FAIL_INTERNAL_ERROR,
438 "Bad peer_gone msg from connectd: %s",
439 tal_hex(tmpctx, msg));
440 }
441
442 peer = find_peer(daemon, &id);
443 if (!peer)
444 status_broken("Peer %s already gone?",
445 type_to_string(tmpctx, struct node_id, &id));
446 tal_free(peer);
447}
448
449/*~ lightningd asks us if we know any addresses for a given id. */
450static struct io_plan *handle_get_address(struct io_conn *conn,

Callers 1

connectd_reqFunction · 0.85

Calls 5

tal_hexFunction · 0.85
tal_freeFunction · 0.85
find_peerFunction · 0.70
status_failedFunction · 0.50
type_to_stringClass · 0.50

Tested by

no test coverage detected