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

Function gossmap_node_get_id

common/gossmap.c:980–990  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

978}
979
980void gossmap_node_get_id(const struct gossmap *map,
981 const struct gossmap_node *node,
982 struct node_id *id)
983{
984 /* We extract nodeid from first channel. */
985 int dir;
986 struct gossmap_chan *c = gossmap_nth_chan(map, node, 0, &dir);
987
988 map_nodeid(map, c->cann_off + c->plus_scid_off
989 + 8 + PUBKEY_CMPR_LEN*dir, id);
990}
991
992bool gossmap_chan_get_capacity(const struct gossmap *map,
993 const struct gossmap_chan *c,

Callers 11

dijkstra_to_hopsFunction · 0.85
nodeidx_idFunction · 0.85
node_parityFunction · 0.85
dst_is_excludedFunction · 0.85
can_carryFunction · 0.85
json_add_halfchanFunction · 0.85
json_add_nodeFunction · 0.85
json_listincomingFunction · 0.85
mainFunction · 0.85
measure_least_costFunction · 0.85

Calls 2

gossmap_nth_chanFunction · 0.85
map_nodeidFunction · 0.85

Tested by

no test coverage detected