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

Function towire_wally_tx_input

bitcoin/tx_parts.c:318–348  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

316}
317
318static void towire_wally_tx_input(u8 **pptr, const struct wally_tx_input *in)
319{
320 /* Just like a bitcoin_txid */
321 towire_u8_array(pptr, in->txhash, sizeof(in->txhash));
322 towire_u32(pptr, in->index);
323 towire_u32(pptr, in->sequence);
324 towire_u32(pptr, in->script_len);
325 towire_u8_array(pptr, in->script, in->script_len);
326 towire_wally_tx_witness_stack(pptr, in->witness);
327
328 if (is_elements(chainparams)) {
329 towire_u32(pptr, sizeof(in->blinding_nonce));
330 towire_u8_array(pptr, in->blinding_nonce,
331 sizeof(in->blinding_nonce));
332 towire_u32(pptr, sizeof(in->entropy));
333 towire_u8_array(pptr, in->entropy, sizeof(in->entropy));
334 towire_u32(pptr, in->issuance_amount_len);
335 towire_u8_array(pptr, in->issuance_amount,
336 in->issuance_amount_len);
337 towire_u32(pptr, in->inflation_keys_len);
338 towire_u8_array(pptr, in->inflation_keys,
339 in->inflation_keys_len);
340 towire_u32(pptr, in->issuance_amount_rangeproof_len);
341 towire_u8_array(pptr, in->issuance_amount_rangeproof,
342 in->issuance_amount_rangeproof_len);
343 towire_u32(pptr, in->inflation_keys_rangeproof_len);
344 towire_u8_array(pptr, in->inflation_keys_rangeproof,
345 in->inflation_keys_rangeproof_len);
346 towire_wally_tx_witness_stack(pptr, in->pegin_witness);
347 }
348}
349
350static void towire_wally_tx_output(u8 **pptr, const struct wally_tx_output *out)
351{

Callers 1

towire_tx_partsFunction · 0.85

Calls 4

is_elementsFunction · 0.85
towire_u8_arrayFunction · 0.50
towire_u32Function · 0.50

Tested by

no test coverage detected