Skip to content

Commit

Permalink
fix(loader): inspect all relas, not only relative ones
Browse files Browse the repository at this point in the history
  • Loading branch information
mkroening committed Aug 5, 2024
1 parent a9fa802 commit 1ec8c08
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/elf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ impl<'a> KernelObject<'a> {

let relas = {
let start = dynamic_info.rela;
let len = dynamic_info.relacount;
let len = dynamic_info.relasz / reloc::SIZEOF_RELA;
Rela::slice_from_bytes_len(&elf[start..], len).unwrap()
};

Expand Down

0 comments on commit 1ec8c08

Please sign in to comment.