| 8 | #include <lightningd/log.h> |
| 9 | |
| 10 | size_t hash_htlc_key(const struct htlc_key *k) |
| 11 | { |
| 12 | struct siphash24_ctx ctx; |
| 13 | siphash24_init(&ctx, siphash_seed()); |
| 14 | /* channel doesn't move while in this hash, so we just hash pointer. */ |
| 15 | siphash24_update(&ctx, &k->channel, sizeof(k->channel)); |
| 16 | siphash24_u64(&ctx, k->id); |
| 17 | |
| 18 | return siphash24_done(&ctx); |
| 19 | } |
| 20 | |
| 21 | struct htlc_in *find_htlc_in(const struct htlc_in_map *map, |
| 22 | const struct channel *channel, |
nothing calls this directly
no test coverage detected