Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit db9697b3 authored by Elliott Hughes's avatar Elliott Hughes Committed by Android Git Automerger
Browse files

am b94b038d: Merge "libcorkscrew will always HAVE_DLADDR."

# Via Elliott Hughes (1) and Gerrit Code Review (1)
* commit 'b94b038d':
  libcorkscrew will always HAVE_DLADDR.
parents 35d5b7e6 b94b038d
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -35,10 +35,8 @@
#include <cutils/atomic.h>
#include <elf.h>

#if HAVE_DLADDR
#define __USE_GNU // For dladdr(3) in glibc.
#include <dlfcn.h>
#endif

#if defined(__BIONIC__)

@@ -256,7 +254,6 @@ void get_backtrace_symbols(const backtrace_frame_t* backtrace, size_t frames,
            if (mi->name[0]) {
                symbol->map_name = strdup(mi->name);
            }
#if HAVE_DLADDR
            Dl_info info;
            if (dladdr((const void*)frame->absolute_pc, &info) && info.dli_sname) {
                symbol->relative_symbol_addr = (uintptr_t)info.dli_saddr
@@ -264,7 +261,6 @@ void get_backtrace_symbols(const backtrace_frame_t* backtrace, size_t frames,
                symbol->symbol_name = strdup(info.dli_sname);
                symbol->demangled_name = demangle_symbol_name(symbol->symbol_name);
            }
#endif
        }
    }
    release_my_map_info_list(milist);