mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-03 22:34:21 +01:00
gossipd: neaten node_has_broadcastable_channels logic.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Alex Myers
parent
73e50b26f9
commit
9e93826eea
@@ -424,8 +424,10 @@ static bool node_has_broadcastable_channels(struct node *node)
|
||||
for (c = first_chan(node, &i); c; c = next_chan(node, &i)) {
|
||||
if (!is_chan_public(c))
|
||||
continue;
|
||||
if ((is_halfchan_defined(&c->half[0])
|
||||
|| is_halfchan_defined(&c->half[1])) && !is_chan_zombie(c))
|
||||
if (is_chan_zombie(c))
|
||||
continue;
|
||||
if (is_halfchan_defined(&c->half[0])
|
||||
|| is_halfchan_defined(&c->half[1]))
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user