diff options
author | Karl-Johan Alm <karljohan-alm@garage.co.jp> | 2019-04-25 13:50:07 +0900 |
---|---|---|
committer | Karl-Johan Alm <karljohan-alm@garage.co.jp> | 2019-05-29 18:40:31 +0900 |
commit | 27669551da52099e4a6a401acd7aa32b32832423 (patch) | |
tree | db861c209efa4d92deb95b19f69de2b783e548c5 /src/wallet | |
parent | 8f2e208f7c0468f9ba92bc789a698281b1c81284 (diff) |
wallet: enable avoid_partial_spends by default if avoid_reuse is set
Diffstat (limited to 'src/wallet')
-rw-r--r-- | src/wallet/rpcwallet.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/wallet/rpcwallet.cpp b/src/wallet/rpcwallet.cpp index 237fb2837a..e3080ae96e 100644 --- a/src/wallet/rpcwallet.cpp +++ b/src/wallet/rpcwallet.cpp @@ -448,6 +448,8 @@ static UniValue sendtoaddress(const JSONRPCRequest& request) } coin_control.m_avoid_address_reuse = GetAvoidReuseFlag(pwallet, request.params[8]); + // We also enable partial spend avoidance if reuse avoidance is set. + coin_control.m_avoid_partial_spends |= coin_control.m_avoid_address_reuse; EnsureWalletIsUnlocked(pwallet); |