Skip to content

Commit

Permalink
adding changes from fvm
Browse files Browse the repository at this point in the history
  • Loading branch information
laudiacay committed Dec 8, 2021
1 parent 453cba1 commit fd236c6
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions vm/actor/src/builtin/miner/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1153,6 +1153,11 @@ impl State {
let precommitted =
make_map_with_root_and_bitwidth(&self.pre_committed_sectors, store, HAMT_BIT_WIDTH)?;
for sector_no in sector_nos.iter() {
if sector_no > fil_types::MAX_SECTOR_NUMBER as usize {
return Err(
actor_error!(ErrIllegalArgument, "sector number greater than maximum").into(),
);
}
let info: &SectorPreCommitOnChainInfo =
precommitted
.get(&u64_key(sector_no as u64))?
Expand Down

0 comments on commit fd236c6

Please sign in to comment.