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

Function htlc_offer_timeout

lightningd/peer_htlcs.c:555–574  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

553}
554
555static void htlc_offer_timeout(struct htlc_out *out)
556{
557 struct channel *channel = out->key.channel;
558
559 out->timeout = NULL;
560
561 /* Otherwise, timer would be removed. */
562 assert(out->hstate == SENT_ADD_HTLC);
563
564 /* If owner died, we should already be taken care of. */
565 if (!channel->owner || channel->state != CHANNELD_NORMAL)
566 return;
567
568 log_unusual(channel->owner->log,
569 "Adding HTLC %"PRIu64" too slow: killing connection",
570 out->key.id);
571 tal_free(channel->owner);
572 channel_set_billboard(channel, false,
573 "Adding HTLC timed out: killed connection");
574}
575
576/* Returns failmsg, or NULL on success. */
577const u8 *send_htlc_out(const tal_t *ctx,

Callers

nothing calls this directly

Calls 2

tal_freeFunction · 0.85
channel_set_billboardFunction · 0.85

Tested by

no test coverage detected