dual-fund: rework where we send our tx-sigs message, allow peers in

Prior to this patch update, we expected a client to call
`openchannel_signed` before checking for peer's tx-sigs messages on the
wire.

When moving to a 'multifundchannel' approach, we'll need to be able to
collect sigs from our peers before sending our tx_sigs message. There's
no strict ordering on when tx-sigs messages are sent/received, so this
is fine.

To do this, we go ahead and start up channeld as soon as
commitment_sigs are secured, so that we process incoming tx-sigs from
our peers as soon as we get them.
This commit is contained in:
niftynei
2020-10-08 17:12:20 -05:00
committed by Rusty Russell
parent c6ad4f9b20
commit f9aab50ee8
7 changed files with 256 additions and 131 deletions

View File

@@ -151,10 +151,6 @@ struct channel {
/* PSBT, for v2 channels. Saved until it's sent */
struct wally_psbt *psbt;
/* Stashed pps, saved until channeld is started.
* Needed only for v2 channel open flow */
struct per_peer_state *pps;
};
struct channel *new_channel(struct peer *peer, u64 dbid,