| 951 | } |
| 952 | |
| 953 | struct channel_state_change *new_channel_state_change(const tal_t *ctx, |
| 954 | struct timeabs timestamp, |
| 955 | enum channel_state old_state, |
| 956 | enum channel_state new_state, |
| 957 | enum state_change cause, |
| 958 | const char *message TAKES) |
| 959 | { |
| 960 | struct channel_state_change *c = tal(ctx, struct channel_state_change); |
| 961 | c->timestamp = timestamp; |
| 962 | c->old_state = old_state; |
| 963 | c->new_state = new_state; |
| 964 | c->cause = cause; |
| 965 | c->message = tal_strdup(c, message); |
| 966 | return c; |
| 967 | } |
| 968 | |
| 969 | bool channel_important_filter(const struct channel *channel, void *unused) |
| 970 | { |