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

Function channel_sending_commit

channeld/full_channel.c:1479–1495  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1477}
1478
1479bool channel_sending_commit(struct channel *channel,
1480 const struct htlc ***htlcs)
1481{
1482 int change;
1483 const enum htlc_state states[] = { SENT_ADD_HTLC,
1484 SENT_REMOVE_REVOCATION,
1485 SENT_ADD_REVOCATION,
1486 SENT_REMOVE_HTLC };
1487 status_debug("Trying commit");
1488
1489 change = change_htlcs(channel, REMOTE, states, ARRAY_SIZE(states),
1490 htlcs, "sending_commit");
1491 if (!change)
1492 return false;
1493
1494 return true;
1495}
1496
1497bool channel_rcvd_revoke_and_ack(struct channel *channel,
1498 const struct htlc ***htlcs)

Callers 7

send_commitFunction · 0.85
include_htlcsFunction · 0.85
send_and_fulfill_htlcFunction · 0.85
update_feerateFunction · 0.85
exchange_commitsFunction · 0.85
fuzz_exchange_commitsFunction · 0.85

Calls 1

change_htlcsFunction · 0.85

Tested by 3

include_htlcsFunction · 0.68
send_and_fulfill_htlcFunction · 0.68
update_feerateFunction · 0.68