mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-17 19:03:42 +01:00
channeld: hand in chain_hash.
This will be needed for gossip messages. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
b3514d3430
commit
2b9d3bb0b7
@ -83,6 +83,7 @@ struct peer {
|
||||
*/
|
||||
u64 htlc_id;
|
||||
|
||||
struct sha256_double chain_hash;
|
||||
struct channel_id channel_id;
|
||||
struct channel *channel;
|
||||
|
||||
@ -2004,6 +2005,7 @@ static void init_channel(struct peer *peer)
|
||||
|
||||
msg = wire_sync_read(peer, REQ_FD);
|
||||
if (!fromwire_channel_init(peer, msg, NULL,
|
||||
&peer->chain_hash,
|
||||
&funding_txid, &funding_txout,
|
||||
&funding_satoshi,
|
||||
&peer->conf[LOCAL], &peer->conf[REMOTE],
|
||||
|
@ -22,6 +22,7 @@ channel_normal_operation,1001
|
||||
|
||||
# Begin! (passes gossipd-client fd)
|
||||
channel_init,1
|
||||
channel_init,,chain_hash,struct sha256_double
|
||||
channel_init,,funding_txid,struct sha256_double
|
||||
channel_init,,funding_txout,2
|
||||
channel_init,,funding_satoshi,8
|
||||
|
|
@ -1643,6 +1643,7 @@ static bool peer_start_channeld(struct peer *peer,
|
||||
shutdown_scriptpubkey = NULL;
|
||||
|
||||
initmsg = towire_channel_init(tmpctx,
|
||||
&peer->ld->chainparams->genesis_blockhash,
|
||||
peer->funding_txid,
|
||||
peer->funding_outnum,
|
||||
peer->funding_satoshi,
|
||||
|
Loading…
Reference in New Issue
Block a user