Skip to content

Commit

Permalink
Use LookupResult::skip_all_loads after upgrading addr2line
Browse files Browse the repository at this point in the history
  • Loading branch information
Kai Luo committed May 4, 2023
1 parent b2e26e2 commit a04ee0c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/symbolize/gimli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ pub unsafe fn resolve(what: ResolveWhat<'_>, cb: &mut dyn FnMut(&super::Symbol))
None => return,
};
let mut any_frames = false;
if let Ok(mut frames) = cx.dwarf.find_frames(addr as u64) {
if let Ok(mut frames) = cx.dwarf.find_frames(addr as u64).skip_all_loads() {
while let Ok(Some(frame)) = frames.next() {
any_frames = true;
let name = match frame.function {
Expand All @@ -390,7 +390,7 @@ pub unsafe fn resolve(what: ResolveWhat<'_>, cb: &mut dyn FnMut(&super::Symbol))
}
if !any_frames {
if let Some((object_cx, object_addr)) = cx.object.search_object_map(addr as u64) {
if let Ok(mut frames) = object_cx.dwarf.find_frames(object_addr) {
if let Ok(mut frames) = object_cx.dwarf.find_frames(object_addr).skip_all_loads() {
while let Ok(Some(frame)) = frames.next() {
any_frames = true;
call(Symbol::Frame {
Expand Down

0 comments on commit a04ee0c

Please sign in to comment.