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

Function decode

tests/fuzz/fuzz-wire-open_channel2.c:46–62  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

44}
45
46static struct open_channel2 *decode(const tal_t *ctx, const void *p)
47{
48 struct open_channel2 *s = tal(ctx, struct open_channel2);
49
50 if (fromwire_open_channel2(
51 s, p, &s->chain_hash, &s->temporary_channel_id,
52 &s->funding_feerate_perkw, &s->commitment_feerate_perkw,
53 &s->funding_satoshis, &s->dust_limit_satoshis,
54 &s->max_htlc_value_in_flight_msat, &s->htlc_minimum_msat,
55 &s->to_self_delay, &s->max_accepted_htlcs, &s->locktime,
56 &s->funding_pubkey, &s->revocation_basepoint,
57 &s->payment_basepoint, &s->delayed_payment_basepoint,
58 &s->htlc_basepoint, &s->first_per_commitment_point,
59 &s->second_per_commitment_point, &s->channel_flags, &s->tlvs))
60 return s;
61 return tal_free(s);
62}
63
64static bool request_funds_equal(const struct tlv_opening_tlvs_request_funds *x,
65 const struct tlv_opening_tlvs_request_funds *y)

Callers

nothing calls this directly

Calls 1

tal_freeFunction · 0.85

Tested by

no test coverage detected