Browse Source

dual-fund: use correct 'last_tx'

We were incorrectly saving the *remote's* commitment transaction as the
'last_tx' for a peer, not our own local one.

When we applied the 'remote_commit_sig' to it, it would fail since the
remote's signature doesn't validate for their commitment transaction.
ppa
niftynei 4 years ago
committed by Christian Decker
parent
commit
c3a387a6d8
  1. 4
      openingd/dualopend.c

4
openingd/dualopend.c

@ -1765,7 +1765,7 @@ static void accepter_start(struct state *state, const u8 *oc2_msg)
* then wait to get our sigs back */
msg = towire_dualopend_commit_rcvd(state,
&state->remoteconf,
remote_commit,
local_commit,
pbase,
&remote_sig,
state->psbt,
@ -2209,7 +2209,7 @@ static void opener_start(struct state *state, u8 *msg)
msg = towire_dualopend_commit_rcvd(NULL,
&state->remoteconf,
remote_commit,
local_commit,
pbase,
&remote_sig,
state->psbt,

Loading…
Cancel
Save