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

Function decode

tests/fuzz/fuzz-wire-open_channel.c:44–59  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

42}
43
44static struct open_channel *decode(const tal_t *ctx, const void *p)
45{
46 struct open_channel *s = tal(ctx, struct open_channel);
47
48 if (fromwire_open_channel(
49 s, p, &s->chain_hash, &s->temporary_channel_id,
50 &s->funding_satoshis, &s->push_msat, &s->dust_limit_satoshis,
51 &s->max_htlc_value_in_flight_msat, &s->channel_reserve_satoshis,
52 &s->htlc_minimum_msat, &s->feerate_per_kw, &s->to_self_delay,
53 &s->max_accepted_htlcs, &s->funding_pubkey,
54 &s->revocation_basepoint, &s->payment_basepoint,
55 &s->delayed_payment_basepoint, &s->htlc_basepoint,
56 &s->first_per_commitment_point, &s->channel_flags, &s->tlvs))
57 return s;
58 return tal_free(s);
59}
60
61static bool equal(const struct open_channel *x, const struct open_channel *y)
62{

Callers

nothing calls this directly

Calls 1

tal_freeFunction · 0.85

Tested by

no test coverage detected