mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-06 15:44:21 +01:00
txs: Move commit tx generation out of the signature computation
We need the txs around, so don't throw them away after generating them.
This commit is contained in:
committed by
Rusty Russell
parent
667a763659
commit
eb8eabcc3c
@@ -272,6 +272,7 @@ static void add_htlcs(struct bitcoin_tx ***txs,
|
||||
/* FIXME: We could cache these. */
|
||||
struct bitcoin_tx **channel_txs(const tal_t *ctx,
|
||||
const struct htlc ***htlcmap,
|
||||
struct wally_tx_output *direct_outputs[NUM_SIDES],
|
||||
const u8 **funding_wscript,
|
||||
const struct channel *channel,
|
||||
const struct pubkey *per_commitment_point,
|
||||
@@ -299,8 +300,9 @@ struct bitcoin_tx **channel_txs(const tal_t *ctx,
|
||||
channel->config[!side].to_self_delay, &keyset,
|
||||
channel_feerate(channel, side),
|
||||
channel->config[side].dust_limit, channel->view[side].owed[side],
|
||||
channel->view[side].owed[!side], committed, htlcmap,
|
||||
commitment_number ^ channel->commitment_number_obscurer, side);
|
||||
channel->view[side].owed[!side], committed, htlcmap, direct_outputs,
|
||||
commitment_number ^ channel->commitment_number_obscurer,
|
||||
side);
|
||||
|
||||
/* Generating and saving witness script required to spend
|
||||
* the funding output */
|
||||
|
||||
Reference in New Issue
Block a user