bitcoin/short_channel_id: pass by copy everywhere.

It's a u64, we should pass by copy.  This is a big sweeping change,
but mainly mechanical (change one, compile, fix breakage, repeat).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2024-03-20 12:29:51 +10:30
parent 98f491a5d0
commit 9450d46db1
73 changed files with 355 additions and 319 deletions

View File

@@ -1574,7 +1574,7 @@ enum watch_result onchaind_funding_spent(struct channel *channel,
/* This could be a mutual close, but it doesn't matter.
* We don't need this for stub channels as well */
if (!is_stub_scid(channel->scid))
if (!channel->scid || !is_stub_scid(*channel->scid))
bitcoin_txid(channel->last_tx, &our_last_txid);
else
/* Dummy txid for stub channel to make valgrind happy. */