solana/ledger
behzad nouri e08139f949
uses Option<u64> for SlotMeta.last_index (#21775)
SlotMeta.last_index may be unknown and current code is using u64::MAX to
indicate that:
https://github.com/solana-labs/solana/blob/6c108c8fc/ledger/src/blockstore_meta.rs#L169-L174

This lacks type-safety and can introduce bugs if not always checked for
Several instances of slot_meta.last_index + 1 are also subject to
overflow.

This commit updates the type to Option<u64>. Backward compatibility is
maintained by customizing serde serialize/deserialize implementations.
2021-12-11 14:47:20 +00:00
..
benches Rename Packets to PacketBatch (#21794) 2021-12-11 09:44:15 -05:00
src uses Option<u64> for SlotMeta.last_index (#21775) 2021-12-11 14:47:20 +00:00
tests Reformat imports to a consistent style for imports 2021-12-03 09:19:13 -08:00
.gitignore system_instruction_processor updates (#6448) 2019-10-19 18:23:27 -07:00
Cargo.toml chore: bump serde from 1.0.130 to 1.0.131 (#21758) 2021-12-10 08:47:46 +00:00
build.rs adds crds-value for broadcasting duplicate shreds through gossip (#14133) 2020-12-18 14:32:43 +00:00