From 31a373571bc6304ea23da1838ccf809e1b98aeff Mon Sep 17 00:00:00 2001 From: JoeGruff Date: Thu, 13 Feb 2020 16:46:57 +0900 Subject: [PATCH] rpcserver: Correctly assign TxIn amounts Use the passed amounts instead of wire.NullValueIn for inputs to the transaction in handleCreateRawSSTx. Use nil instead of an empty slice. --- rpcserver.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpcserver.go b/rpcserver.go index 32963c17..d22a7ec4 100644 --- a/rpcserver.go +++ b/rpcserver.go @@ -735,7 +735,7 @@ func handleCreateRawSStx(_ context.Context, s *rpcServer, cmd interface{}) (inte } prevOut := wire.NewOutPoint(txHash, input.Vout, input.Tree) - txIn := wire.NewTxIn(prevOut, wire.NullValueIn, []byte{}) + txIn := wire.NewTxIn(prevOut, input.Amt, nil) mtx.AddTxIn(txIn) }