mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-17 19:03:42 +01:00
gossip: Do not consider half-open connections for routes
Connections are in a half-open state after receiving the `channel_announcement` and before the `channel_update` makes them usable, so we need to ignore channels that are not yet fully open.
This commit is contained in:
parent
611f4833c5
commit
e54c0adced
@ -388,6 +388,8 @@ struct peer *find_route(const tal_t *ctx,
|
||||
n = node_map_next(dstate->nodes, &it)) {
|
||||
size_t num_edges = tal_count(n->in);
|
||||
for (i = 0; i < num_edges; i++) {
|
||||
if (!n->in[i]->active)
|
||||
continue;
|
||||
bfg_one_edge(n, i, riskfactor);
|
||||
log_debug(dstate->base_log, "We seek %p->%p, this is %p -> %p",
|
||||
dst, src, n->in[i]->src, n->in[i]->dst);
|
||||
|
Loading…
Reference in New Issue
Block a user