Skip to content

Commit

Permalink
size is a usize
Browse files Browse the repository at this point in the history
  • Loading branch information
s1341 committed Jan 4, 2024
1 parent 6c225b5 commit 9bfa5f1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions frida-gum/src/range_details.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ pub enum PageProtection {
#[derive(Clone)]
pub struct FileMapping<'a> {
path: &'a str,
size: u64,
size: usize,
offset: u64,
phantom: PhantomData<&'a gum_sys::GumFileMapping>,
}
Expand All @@ -56,7 +56,7 @@ impl<'a> FileMapping<'a> {
Some(unsafe {
Self {
path: CStr::from_ptr((*file).path).to_str().unwrap(),
size: (*file).size,
size: (*file).size as usize,
offset: (*file).offset,
phantom: PhantomData,
}
Expand All @@ -75,8 +75,8 @@ impl<'a> FileMapping<'a> {
}

/// The size of the mapping.
pub fn size(&self) -> u64 {
self.size
pub fn size(&self) -> usize {
self.size as usize
}
}

Expand Down

0 comments on commit 9bfa5f1

Please sign in to comment.