Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Commit

Permalink
Fix sorting order of stakes in confirmation time calculations
Browse files Browse the repository at this point in the history
  • Loading branch information
pgarg66 authored and solana-grimes committed Mar 6, 2019
1 parent 0252bf2 commit 9163e5b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion runtime/src/bank.rs
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ impl Bank {
supermajority_stake: u64,
) -> Option<u64> {
// Sort by slot height
slots_and_stakes.sort_by(|a, b| a.0.cmp(&b.0));
slots_and_stakes.sort_by(|a, b| b.0.cmp(&a.0));

let max_slot = self.slot();
let min_slot = max_slot.saturating_sub(MAX_RECENT_BLOCKHASHES as u64);
Expand Down

0 comments on commit 9163e5b

Please sign in to comment.