Unstable sort slots when generating index (#32653)

This commit is contained in:
Brooks 2023-07-29 22:28:33 -04:00 committed by GitHub
parent ad4ddd3cb0
commit fc8cfb63ae
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -8937,8 +8937,7 @@ impl AccountsDb {
genesis_config: &GenesisConfig,
) -> IndexGenerationInfo {
let mut slots = self.storage.all_slots();
#[allow(clippy::stable_sort_primitive)]
slots.sort();
slots.sort_unstable();
if let Some(limit) = limit_load_slot_count_from_snapshot {
slots.truncate(limit); // get rid of the newer slots and keep just the older
}