MCPcopy Create free account
hub / github.com/ElementsProject/lightning / equal

Function equal

tests/fuzz/fuzz-wire-closing_complete.c:32–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

30}
31
32static bool equal(const struct closing_complete *x,
33 const struct closing_complete *y)
34{
35 assert(memcmp(&x->channel_id, &y->channel_id, sizeof(x->channel_id)) == 0);
36 assert(x->locktime == y->locktime);
37 assert(memcmp(&x->fee_satoshis, &y->fee_satoshis, sizeof(x->fee_satoshis)) == 0);
38
39 assert(tal_arr_eq(x->closer_scriptpubkey, y->closer_scriptpubkey));
40 assert(tal_arr_eq(x->closee_scriptpubkey, y->closee_scriptpubkey));
41
42 assert(x->tlvs && y->tlvs);
43 assert(tal_arr_eq(x->tlvs->closer_output_only, y->tlvs->closer_output_only));
44 assert(tal_arr_eq(x->tlvs->closee_output_only, y->tlvs->closee_output_only));
45
46 return tal_arr_eq(x->tlvs->closer_and_closee_outputs, y->tlvs->closer_and_closee_outputs);
47}
48
49void run(const u8 *data, size_t size)
50{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected