mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 15:14:23 +01:00
close_tx: use version 2.
As per the pending spec change: the other implementations use version 2, and the current best practice advice (from maaku) is to use the latest defined tx version. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Christian Decker
parent
06d7c40c63
commit
ed60e9ee57
@@ -24,13 +24,12 @@ struct bitcoin_tx *create_close_tx(const tal_t *ctx,
|
|||||||
*
|
*
|
||||||
* Note that there are two possible variants for each node.
|
* Note that there are two possible variants for each node.
|
||||||
*
|
*
|
||||||
* * version: 1
|
* * version: 2
|
||||||
* * locktime: 0
|
* * locktime: 0
|
||||||
* * txin count: 1
|
* * txin count: 1
|
||||||
*/
|
*/
|
||||||
/* Now create close tx: one input, two outputs. */
|
/* Now create close tx: one input, two outputs. */
|
||||||
tx = bitcoin_tx(ctx, 1, 2);
|
tx = bitcoin_tx(ctx, 1, 2);
|
||||||
tx->version = 1;
|
|
||||||
|
|
||||||
/* Our input spends the anchor tx output. */
|
/* Our input spends the anchor tx output. */
|
||||||
tx->input[0].txid = *anchor_txid;
|
tx->input[0].txid = *anchor_txid;
|
||||||
|
|||||||
Reference in New Issue
Block a user