diff options
author | Sjors Provoost <sjors@sprovoost.nl> | 2019-07-12 13:30:10 +0100 |
---|---|---|
committer | Sjors Provoost <sjors@sprovoost.nl> | 2020-03-12 13:07:17 +0100 |
commit | 79804fe24bd00e183382dfbcab9343960d158aa5 (patch) | |
tree | 297bd50ec5f73a77af0d2e7e9104bc22919f9136 /src/wallet/coincontrol.cpp | |
parent | 5c73645ac79f1d12611051d2e9467a003383ffd9 (diff) |
[rpc] walletcreatefundedpsbt: don't automatically append inputs
When the user doesn't specificy inputs, it makes sense to automatically select them. But when the user does specify inputs, we now fail if the amount is insufficient, unless addInputs is set to true.
Diffstat (limited to 'src/wallet/coincontrol.cpp')
-rw-r--r-- | src/wallet/coincontrol.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wallet/coincontrol.cpp b/src/wallet/coincontrol.cpp index c83e598825..720877ead0 100644 --- a/src/wallet/coincontrol.cpp +++ b/src/wallet/coincontrol.cpp @@ -10,6 +10,7 @@ void CCoinControl::SetNull() { destChange = CNoDestination(); m_change_type.reset(); + m_add_inputs = true; fAllowOtherInputs = false; fAllowWatchOnly = false; m_avoid_partial_spends = gArgs.GetBoolArg("-avoidpartialspends", DEFAULT_AVOIDPARTIALSPENDS); @@ -23,4 +24,3 @@ void CCoinControl::SetNull() m_min_depth = DEFAULT_MIN_DEPTH; m_max_depth = DEFAULT_MAX_DEPTH; } - |