lightningd: log BROKEN if we lost funds, only unusual if we closed abandoned HTLC.
Started seeing these in my logs, and it's the wrong way around! Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Vincenzo Palazzo
parent
0afaf2f3ca
commit
db67df3364
@@ -1435,7 +1435,7 @@ static void fulfill_our_htlc_out(struct channel *channel, struct htlc_out *hout,
|
||||
/* Did we abandon the incoming? Oops! */
|
||||
if (hout->in->failonion) {
|
||||
/* FIXME: Accounting? */
|
||||
log_unusual(channel->log, "FUNDS LOSS of %s: peer took funds onchain before we could time out the HTLC, but we abandoned incoming HTLC to save the incoming channel",
|
||||
log_broken(channel->log, "FUNDS LOSS of %s: peer took funds onchain before we could time out the HTLC, but we abandoned incoming HTLC to save the incoming channel",
|
||||
fmt_amount_msat(tmpctx, hout->msat));
|
||||
} else {
|
||||
struct short_channel_id scid = channel_scid_or_local_alias(hout->key.channel);
|
||||
@@ -1752,8 +1752,9 @@ void onchain_failed_our_htlc(const struct channel *channel,
|
||||
? fromwire_peektype(hout->failmsg)
|
||||
: 0);
|
||||
} else {
|
||||
log_broken(channel->log, "HTLC id %"PRIu64" is from nowhere?",
|
||||
htlc->id);
|
||||
/* This happens if we abandoned the incoming HTLC to avoid closure */
|
||||
log_unusual(channel->log, "HTLC id %"PRIu64" is from nowhere: did we abandon it?",
|
||||
htlc->id);
|
||||
|
||||
/* Immediate corruption sanity check if this happens */
|
||||
htable_check(&ld->htlcs_out->raw, "onchain_failed_our_htlc out");
|
||||
|
||||
Reference in New Issue
Block a user