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

Function new_tx_state

openingd/dualopend.c:128–148  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

126};
127
128static struct tx_state *new_tx_state(const tal_t *ctx)
129{
130 struct tx_state *tx_state = tal(ctx, struct tx_state);
131 tx_state->psbt = NULL;
132 tx_state->remote_funding_sigs_rcvd = false;
133
134 tx_state->lease_expiry = 0;
135 tx_state->lease_fee = AMOUNT_SAT(0);
136 tx_state->blockheight = 0;
137 tx_state->lease_commit_sig = NULL;
138 tx_state->lease_chan_max_msat = 0;
139 tx_state->lease_chan_max_ppt = 0;
140
141 /* no max_htlc_dust_exposure on remoteconf, we exclusively use the local's */
142 tx_state->remoteconf.max_dust_htlc_exposure_msat = AMOUNT_MSAT(0);
143
144 for (size_t i = 0; i < NUM_TX_MSGS; i++)
145 tx_state->tx_msg_count[i] = 0;
146
147 return tx_state;
148}
149
150/* Global state structure. This is only for the one specific peer and channel */
151struct state {

Callers 3

rbf_local_startFunction · 0.85
rbf_remote_startFunction · 0.85
mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected