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

Function psbt_find_serial_output

common/psbt_open.c:356–366  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

354}
355
356int psbt_find_serial_output(struct wally_psbt *psbt, u64 serial_id)
357{
358 for (size_t i = 0; i < psbt->num_outputs; i++) {
359 u64 out_serial;
360 if (!psbt_get_serial_id(&psbt->outputs[i].unknowns, &out_serial))
361 continue;
362 if (out_serial == serial_id)
363 return i;
364 }
365 return -1;
366}
367
368static u64 get_random_serial(enum tx_role role)
369{

Callers 5

psbt_new_output_serialFunction · 0.85
change_serialsFunction · 0.85
update_parent_psbtFunction · 0.85
update_node_psbtFunction · 0.85
run_tx_interactiveFunction · 0.85

Calls 1

psbt_get_serial_idFunction · 0.85

Tested by 1

change_serialsFunction · 0.68