Skip to content

Commit

Permalink
Merge pull request gimli-rs#515 from jrmuizel/dont-fail
Browse files Browse the repository at this point in the history
Don't fail if unable to read the string for DW_AT_comp_dir or DW_AT_name
  • Loading branch information
philipc authored Jun 26, 2020
2 parents ea707d7 + 6172c70 commit e40ff75
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/read/dwarf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -608,11 +608,11 @@ impl<R: Reader> Unit<R> {
}

unit.name = match name {
Some(val) => Some(dwarf.attr_string(&unit, val)?),
Some(val) => dwarf.attr_string(&unit, val).ok(),
None => None,
};
unit.comp_dir = match comp_dir {
Some(val) => Some(dwarf.attr_string(&unit, val)?),
Some(val) => dwarf.attr_string(&unit, val).ok(),
None => None,
};
unit.line_program = match line_program_offset {
Expand Down

0 comments on commit e40ff75

Please sign in to comment.