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

Function commit_tx_send_finished

lightningd/peer_control.c:303–322  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

301}
302
303static bool commit_tx_send_finished(struct channel *channel,
304 const struct bitcoin_tx *tx,
305 bool success,
306 const char *err,
307 struct anchor_details *adet)
308{
309 struct bitcoin_txid txid;
310
311 bitcoin_txid(tx, &txid);
312
313 /* If it's already mined, stop retransmitting, stop boosting. */
314 if (wallet_transaction_height(channel->peer->ld->wallet, &txid) != 0) {
315 tal_free(adet);
316 return true;
317 }
318
319 /* Boost (if possible), and keep trying! */
320 commit_tx_boost(channel, adet, success);
321 return false;
322}
323
324static struct bitcoin_tx *sign_and_send_last(const tal_t *ctx,
325 struct lightningd *ld,

Callers

nothing calls this directly

Calls 4

tal_freeFunction · 0.85
bitcoin_txidClass · 0.70
commit_tx_boostFunction · 0.70

Tested by

no test coverage detected