1
0
Fork 0
forked from lthn/blockchain

fixed problem with decoy selection algo

This commit is contained in:
cryptozoidberg 2024-03-28 19:22:20 +01:00
parent 4d6aa1a4f9
commit 312d500a36
No known key found for this signature in database
GPG key ID: 2E10CC61CAC8F36D

View file

@ -6250,6 +6250,12 @@ void wallet2::select_decoys(currency::COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS
{
out_entry entry = extract_random_from_container(amount_entry.outs);
//
if (entry.global_amount_index == own_g_index)
{
continue;
}
//skip auditable
if ((entry.flags & (RANDOM_OUTPUTS_FOR_AMOUNTS_FLAGS_NOT_ALLOWED)))
{
@ -6260,11 +6266,7 @@ void wallet2::select_decoys(currency::COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS
coinbases.push_back(entry);
continue;
}
//
if (entry.global_amount_index == own_g_index)
{
continue;
}
local_outs.push_back(entry);
}