Allow ConstructTransaction to not throw error with 0-input txn

Github-Pull: #13968
Rebased-From: 2252ec5008
Tree-SHA512: 1f9978ee25fbe9bb338af19d81b401fa531d314ac8288cdb21c1bf10459edea50b43e2d5e97c9bb5fe24c8db89363f8233c0a3d96066ed85f7bd6d2eb234aac0
This commit is contained in:
Gregory Sanders 2018-08-14 14:28:29 -04:00 committed by Wladimir J. van der Laan
parent 1ffd67f11f
commit c6d905746b
No known key found for this signature in database
GPG key ID: 1E4AED62986CD25D

View file

@ -436,7 +436,7 @@ CMutableTransaction ConstructTransaction(const UniValue& inputs_in, const UniVal
} }
} }
if (!rbf.isNull() && rbfOptIn != SignalsOptInRBF(rawTx)) { if (!rbf.isNull() && rawTx.vin.size() > 0 && rbfOptIn != SignalsOptInRBF(rawTx)) {
throw JSONRPCError(RPC_INVALID_PARAMETER, "Invalid parameter combination: Sequence number(s) contradict replaceable option"); throw JSONRPCError(RPC_INVALID_PARAMETER, "Invalid parameter combination: Sequence number(s) contradict replaceable option");
} }