Skip to content

Commit

Permalink
Use get_at method in parese_elf target
Browse files Browse the repository at this point in the history
  • Loading branch information
anfedotoff committed Jan 2, 2023
1 parent f4ab557 commit d140a56
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion fuzz-afl/fuzz_targets/afl_parse_elf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ fn main() {
fuzz!(|data: &[u8]| {
if let Ok(elf) = goblin::elf::Elf::parse(data) {
for section_header in &elf.section_headers {
let _ = elf.shdr_strtab.get(section_header.sh_name);
let _ = elf.shdr_strtab.get_at(section_header.sh_name);
}

for _relocation in &elf.dynrels {}
Expand Down
2 changes: 1 addition & 1 deletion fuzz/fuzz_targets/parse_elf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use libfuzzer_sys::fuzz_target;
fuzz_target!(|data: &[u8]| {
if let Ok(elf) = goblin::elf::Elf::parse(data) {
for section_header in &elf.section_headers {
let _ = elf.shdr_strtab.get(section_header.sh_name);
let _ = elf.shdr_strtab.get_at(section_header.sh_name);
}

for _relocation in &elf.dynrels {}
Expand Down

0 comments on commit d140a56

Please sign in to comment.