Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
Signed-off-by: Jean-François Morcillo <[email protected]>
  • Loading branch information
Jean-François Morcillo committed Jun 26, 2023
1 parent 1f4a794 commit 0d0229f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/as_execution/env.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,9 @@ pub(crate) fn get_remaining_points(
} else {
match env.get_exhausted_points().as_ref() {
Some(exhausted_points) => match exhausted_points.get(store).try_into() {
Ok::<u64, _>(exhausted) if exhausted > 0 => return Ok(0),
Ok::<u64, _>(_) => (),
// Using i32 here because it's the type used internally by wasmer for exhausted.
Ok::<i32, _>(exhausted) if exhausted > 0 => return Ok(0),
Ok::<i32, _>(_) => (),
Err(_) => abi_bail!("exhausted_points has wrong type"),
},
None => abi_bail!("Lost reference to exhausted_points"),
Expand Down

0 comments on commit 0d0229f

Please sign in to comment.