Commit e59d167e authored by Mark OLESEN's avatar Mark OLESEN
Browse files

ENH: addr2line for Darwin handles relative addresses for executables

parent e20eaf6a
......@@ -115,13 +115,13 @@ void printSourceFileAndLine
uintptr_t address = uintptr_t(addr);
word myAddress = addressToWord(address);
#ifdef darwin
|| filename.hasExt("dylib")
// Can use relative addresses for executables and libraries with the
// Darwin addr2line implementation.
// On other systems (Linux), only use relative addresses for libraries.
#ifndef darwin
if (filename.hasExt("so"))
// Convert address into offset into dynamic library
uintptr_t offset = uintptr_t(info->dli_fbase);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment