mirror of
https://github.com/monero-project/monero.git
synced 2024-11-18 00:37:43 +00:00
wallet2/create_transactions_2: removed extraneous shuffle before sort of unused_*_indices_per_subaddr
This commit is contained in:
parent
2287fb9fb4
commit
cf646e3afe
1 changed files with 1 additions and 5 deletions
|
@ -8404,12 +8404,8 @@ std::vector<wallet2::pending_tx> wallet2::create_transactions_2(std::vector<cryp
|
|||
}
|
||||
}
|
||||
|
||||
// shuffle & sort output indices
|
||||
// sort output indices
|
||||
{
|
||||
std::random_device rd;
|
||||
std::mt19937 g(rd());
|
||||
std::shuffle(unused_transfers_indices_per_subaddr.begin(), unused_transfers_indices_per_subaddr.end(), g);
|
||||
std::shuffle(unused_dust_indices_per_subaddr.begin(), unused_dust_indices_per_subaddr.end(), g);
|
||||
auto sort_predicate = [&unlocked_balance_per_subaddr] (const std::pair<uint32_t, std::vector<size_t>>& x, const std::pair<uint32_t, std::vector<size_t>>& y)
|
||||
{
|
||||
return unlocked_balance_per_subaddr[x.first] > unlocked_balance_per_subaddr[y.first];
|
||||
|
|
Loading…
Reference in a new issue