lightningd: don't report original depth once splice started.

This is a workaround, the real fix is to use a different
callback for inflight splice attempts, which comes later.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell 2023-10-02 09:29:49 +10:30
parent 58d27c4bdc
commit 328d685a2a

View file

@ -1585,6 +1585,9 @@ bool channel_tell_depth(struct lightningd *ld,
switch (channel->state) {
case CHANNELD_AWAITING_SPLICE:
/* Once we're waiting for splice, don't watch original any more */
if (bitcoin_txid_eq(txid, &channel->funding.txid))
return true;
if (depth >= channel->minimum_depth) {
if (!channel_splice_set_scid(channel, txid))
return false;