diff options
author | Gregory Sanders <gsanders87@gmail.com> | 2018-09-29 22:09:15 -0400 |
---|---|---|
committer | Gregory Sanders <gsanders87@gmail.com> | 2018-09-29 22:09:15 -0400 |
commit | 88a79cb436b30b39d37d139da723f5a31e9d161b (patch) | |
tree | 53ad894377848752690cad04f69be88c58c46c5f /src | |
parent | c9327306b580bb161d1732c0a0260b46c0df015c (diff) |
fix converttopsbt permitsigdata arg, add basic test
Diffstat (limited to 'src')
-rw-r--r-- | src/rpc/rawtransaction.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp index 7397216506..e13a551388 100644 --- a/src/rpc/rawtransaction.cpp +++ b/src/rpc/rawtransaction.cpp @@ -1669,7 +1669,7 @@ UniValue converttopsbt(const JSONRPCRequest& request) // Remove all scriptSigs and scriptWitnesses from inputs for (CTxIn& input : tx.vin) { - if ((!input.scriptSig.empty() || !input.scriptWitness.IsNull()) && (request.params[1].isNull() || (!request.params[1].isNull() && request.params[1].get_bool()))) { + if ((!input.scriptSig.empty() || !input.scriptWitness.IsNull()) && !permitsigdata) { throw JSONRPCError(RPC_DESERIALIZATION_ERROR, "Inputs must not have scriptSigs and scriptWitnesses"); } input.scriptSig.clear(); |