mirror of
https://github.com/Retropex/bitcoin.git
synced 2025-05-29 05:22:30 +02:00
shuffle sendmany recipients ordering to shuffle tx outputs
This commit is contained in:
parent
cead84b72d
commit
cf6ef3c139
@ -1145,6 +1145,9 @@ UniValue sendmany(const JSONRPCRequest& request)
|
||||
if (totalAmount > nBalance)
|
||||
throw JSONRPCError(RPC_WALLET_INSUFFICIENT_FUNDS, "Account has insufficient funds");
|
||||
|
||||
// Shuffle recipient list
|
||||
std::shuffle(vecSend.begin(), vecSend.end(), FastRandomContext());
|
||||
|
||||
// Send
|
||||
CReserveKey keyChange(pwallet);
|
||||
CAmount nFeeRequired = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user