| 168 | } |
| 169 | |
| 170 | struct channel_inflight * |
| 171 | new_inflight(struct channel *channel, |
| 172 | struct pubkey *remote_funding, |
| 173 | const struct bitcoin_outpoint *funding_outpoint, |
| 174 | u32 funding_feerate, |
| 175 | struct amount_sat total_funds, |
| 176 | struct amount_sat our_funds, |
| 177 | struct wally_psbt *psbt STEALS, |
| 178 | const u32 lease_expiry, |
| 179 | const secp256k1_ecdsa_signature *lease_commit_sig, |
| 180 | const u32 lease_chan_max_msat, const u16 lease_chan_max_ppt, |
| 181 | const u32 lease_blockheight_start, |
| 182 | const struct amount_msat lease_fee, |
| 183 | const struct amount_sat lease_amt, |
| 184 | s64 splice_amnt, |
| 185 | bool i_am_initiator, |
| 186 | bool force_sign_first, |
| 187 | bool i_sent_sigs) |
| 188 | { |
| 189 | struct channel_inflight *inflight |
| 190 | = tal(channel, struct channel_inflight); |
| 191 | struct funding_info *funding |
| 192 | = tal(inflight, struct funding_info); |
| 193 | |
| 194 | funding->outpoint = *funding_outpoint; |
| 195 | funding->total_funds = total_funds; |
| 196 | funding->feerate = funding_feerate; |
| 197 | funding->our_funds = our_funds; |
| 198 | funding->splice_amnt = splice_amnt; |
| 199 | funding->splice_remote_funding = tal_steal(funding, remote_funding); |
| 200 | |
| 201 | inflight->funding = funding; |
| 202 | inflight->channel = channel; |
| 203 | inflight->remote_tx_sigs = false; |
| 204 | inflight->funding_psbt = tal_steal(inflight, psbt); |
| 205 | inflight->last_tx = NULL; |
| 206 | inflight->tx_broadcast = false; |
| 207 | inflight->scid = NULL; |
| 208 | |
| 209 | /* Channel lease infos */ |
| 210 | inflight->lease_blockheight_start = lease_blockheight_start; |
| 211 | inflight->lease_expiry = lease_expiry; |
| 212 | inflight->lease_commit_sig |
| 213 | = tal_dup_or_null(inflight, secp256k1_ecdsa_signature, |
| 214 | lease_commit_sig); |
| 215 | |
| 216 | inflight->lease_chan_max_msat = lease_chan_max_msat; |
| 217 | inflight->lease_chan_max_ppt = lease_chan_max_ppt; |
| 218 | inflight->lease_fee = lease_fee; |
| 219 | inflight->lease_amt = lease_amt; |
| 220 | |
| 221 | inflight->i_am_initiator = i_am_initiator; |
| 222 | inflight->force_sign_first = force_sign_first; |
| 223 | inflight->locked_scid = NULL; |
| 224 | inflight->i_sent_sigs = i_sent_sigs; |
| 225 | inflight->splice_locked_memonly = false; |
| 226 | |
| 227 | list_add_tail(&channel->inflights, &inflight->list); |
no outgoing calls
no test coverage detected