~ This cancels the soft-disables when the peer reconnects. */
| 59 | |
| 60 | /*~ This cancels the soft-disables when the peer reconnects. */ |
| 61 | static void peer_enable_channels(struct daemon *daemon, const struct node *node) |
| 62 | { |
| 63 | /* If this peer had a channel with us, mark it disabled. */ |
| 64 | struct chan_map_iter i; |
| 65 | const struct chan *c; |
| 66 | |
| 67 | for (c = first_chan(node, &i); c; c = next_chan(node, &i)) { |
| 68 | int direction; |
| 69 | if (!local_direction(daemon->rstate, c, &direction)) |
| 70 | continue; |
| 71 | local_enable_chan(daemon, c, direction); |
| 72 | } |
| 73 | } |
| 74 | |
| 75 | /*~ Destroy a peer, usually because the per-peer daemon has exited. |
| 76 | * |
no test coverage detected