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

Function fromwire_tal_arrn

wire/fromwire.c:239–254  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

237}
238
239u8 *fromwire_tal_arrn(const tal_t *ctx,
240 const u8 **cursor, size_t *max, size_t num)
241{
242 u8 *arr;
243 if (num == 0)
244 return NULL;
245
246 if (num > *max)
247 return fromwire_fail(cursor, max);
248
249 arr = tal_arr(ctx, u8, num);
250 fromwire_u8_array(cursor, max, arr, num);
251 if (!*cursor)
252 return tal_free(arr);
253 return arr;
254}
255
256void fromwire_pad(const u8 **cursor, size_t *max, size_t num)
257{

Callers 5

fromwire_hsm_utxoFunction · 0.50
fromwire_wally_tx_inputFunction · 0.50
fromwire_wally_tx_outputFunction · 0.50

Calls 3

tal_freeFunction · 0.85
fromwire_failFunction · 0.70
fromwire_u8_arrayFunction · 0.70

Tested by

no test coverage detected