mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-23 00:54:20 +01:00
daemon: use HTLC states.
Since we only care about the latest commits, we can simply associate a state with each HTLC, rather than using queues of HTLCs associated with each commitment transaction. This works far better in the context of a database. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -635,7 +635,7 @@ Pkt *accept_pkt_htlc_add(struct peer *peer, const Pkt *pkt)
|
||||
htlc = peer_new_htlc(peer, u->id, u->amount_msat, &rhash,
|
||||
abs_locktime_to_blocks(&expiry),
|
||||
u->route->info.data, u->route->info.len,
|
||||
NULL, THEIRS);
|
||||
NULL, RCVD_ADD_HTLC);
|
||||
|
||||
/* BOLT #2:
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user