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

Function commit_tx_send_finished

lightningd/peer_control.c:286–305  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

284}
285
286static bool commit_tx_send_finished(struct channel *channel,
287 const struct bitcoin_tx *tx,
288 bool success,
289 const char *err,
290 struct anchor_details *adet)
291{
292 struct bitcoin_txid txid;
293
294 bitcoin_txid(tx, &txid);
295
296 /* If it's already mined, stop retransmitting, stop boosting. */
297 if (wallet_transaction_height(channel->peer->ld->wallet, &txid) != 0) {
298 tal_free(adet);
299 return true;
300 }
301
302 /* Boost (if possible), and keep trying! */
303 commit_tx_boost(channel, adet, success);
304 return false;
305}
306
307static struct bitcoin_tx *sign_and_send_last(const tal_t *ctx,
308 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