| 260 | } |
| 261 | |
| 262 | static void add_to_txout_failures(struct routing_state *rstate, |
| 263 | const struct short_channel_id *scid) |
| 264 | { |
| 265 | if (uintmap_add(&rstate->txout_failures, scid->u64, true) |
| 266 | && ++rstate->num_txout_failures == 10000) { |
| 267 | tal_free(rstate->txout_failure_timer); |
| 268 | txout_failure_age(rstate); |
| 269 | } |
| 270 | } |
| 271 | |
| 272 | static bool in_txout_failures(struct routing_state *rstate, |
| 273 | const struct short_channel_id *scid) |