From 4011f7ae7cabdc847632f9f2a991daca184e1383 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Fri, 3 Jul 2015 10:45:43 +0930 Subject: [PATCH] create-commit-spend-tx: set alpha fields, and input locktime. Signed-off-by: Rusty Russell --- test-cli/create-commit-spend-tx.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test-cli/create-commit-spend-tx.c b/test-cli/create-commit-spend-tx.c index bffc87055..65fcc0e19 100644 --- a/test-cli/create-commit-spend-tx.c +++ b/test-cli/create-commit-spend-tx.c @@ -96,6 +96,11 @@ int main(int argc, char *argv[]) bitcoin_txid(commit, &tx->input[0].txid); p2sh_out = find_p2sh_out(commit, redeemscript); tx->input[0].index = p2sh_out; + tx->input[0].input_amount = commit->output[p2sh_out].amount; + tx->fee = fee; + + /* Sequence number is inverted timeout. */ + tx->input[0].sequence_number = ~locktime; if (commit->output[p2sh_out].amount <= fee) errx(1, "Amount of %llu won't exceed fee",