make find*
functions unsafe
This commit is contained in:
parent
0c750fbdda
commit
a9d5677c57
|
@ -41,7 +41,7 @@ pub struct BlockGroupDescriptor {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl BlockGroupDescriptor {
|
impl BlockGroupDescriptor {
|
||||||
pub fn find_descriptor_table<'a>(
|
pub unsafe fn find_descriptor_table<'a>(
|
||||||
haystack: &'a mut [u8],
|
haystack: &'a mut [u8],
|
||||||
offset: isize,
|
offset: isize,
|
||||||
count: usize,
|
count: usize,
|
||||||
|
|
|
@ -147,7 +147,7 @@ pub struct Superblock {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Superblock {
|
impl Superblock {
|
||||||
pub fn find<'a>(
|
pub unsafe fn find<'a>(
|
||||||
haystack: &'a mut [u8],
|
haystack: &'a mut [u8],
|
||||||
offset: isize,
|
offset: isize,
|
||||||
) -> Result<&'a mut Superblock, Error> {
|
) -> Result<&'a mut Superblock, Error> {
|
||||||
|
|
Reference in a new issue