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

Function channel_rcvd_commit

channeld/full_channel.c:1364–1378  ·  view source on GitHub ↗

FIXME: We can actually merge these two... */

Source from the content-addressed store, hash-verified

1362
1363/* FIXME: We can actually merge these two... */
1364bool channel_rcvd_commit(struct channel *channel, const struct htlc ***htlcs)
1365{
1366 int change;
1367 const enum htlc_state states[] = { RCVD_ADD_REVOCATION,
1368 RCVD_REMOVE_HTLC,
1369 RCVD_ADD_HTLC,
1370 RCVD_REMOVE_REVOCATION };
1371
1372 status_debug("Received commit");
1373 change = change_htlcs(channel, LOCAL, states, ARRAY_SIZE(states),
1374 htlcs, "rcvd_commit");
1375 if (!change)
1376 return false;
1377 return true;
1378}
1379
1380bool channel_sending_revoke_and_ack(struct channel *channel)
1381{

Callers 4

handle_peer_commit_sigFunction · 0.85
include_htlcsFunction · 0.85
send_and_fulfill_htlcFunction · 0.85
update_feerateFunction · 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