mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-04 14:54:26 +01:00
state: don't spend the "to-us" output from their commit tx.
There's no reason to, it's a simple p2wpkh to our key. We still spend the "to-us" from our commit tx, since it could be theoretically be stolen by the revocation value, and it's a complex p2wsh which a normal wallet won't have the information to spend. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -1086,7 +1086,7 @@ bool peer_watch_our_htlc_outputs(struct peer *peer,
|
||||
return false;
|
||||
}
|
||||
bool peer_watch_their_htlc_outputs(struct peer *peer,
|
||||
const struct bitcoin_event *tx,
|
||||
const struct bitcoin_tx *tx,
|
||||
enum state_input tous_timeout,
|
||||
enum state_input tothem_spent,
|
||||
enum state_input tothem_timeout)
|
||||
@@ -1222,13 +1222,6 @@ const struct bitcoin_tx *bitcoin_spend_ours(struct peer *peer)
|
||||
return tx;
|
||||
}
|
||||
|
||||
/* Create a bitcoin spend tx (to spend their commit's outputs) */
|
||||
const struct bitcoin_tx *bitcoin_spend_theirs(const struct peer *peer,
|
||||
const struct bitcoin_event *btc)
|
||||
{
|
||||
FIXME_STUB(peer);
|
||||
}
|
||||
|
||||
/* Create a bitcoin steal tx (to steal all their commit's outputs) */
|
||||
const struct bitcoin_tx *bitcoin_steal(const struct peer *peer,
|
||||
struct bitcoin_event *btc)
|
||||
|
||||
Reference in New Issue
Block a user