Fix stacktrace on aarch64 architecture. Fixes #805 (#827)

* Fix stacktrace on aarch64 architecture

* Tweak formatting to fit in 80 cols
pull/842/head
Roman Gershman 4 years ago committed by GitHub
parent 2e5f2bcfd9
commit 731852f10b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 7
      absl/debugging/internal/stacktrace_aarch64-inl.inc

@ -37,8 +37,11 @@ static const unsigned char* GetKernelRtSigreturnAddress() {
absl::debugging_internal::VDSOSupport vdso;
if (vdso.IsPresent()) {
absl::debugging_internal::VDSOSupport::SymbolInfo symbol_info;
if (!vdso.LookupSymbol("__kernel_rt_sigreturn", "LINUX_2.6.39", STT_FUNC,
&symbol_info) ||
auto lookup = [&](int type) {
return vdso.LookupSymbol("__kernel_rt_sigreturn", "LINUX_2.6.39", type,
&symbol_info);
};
if ((!lookup(STT_FUNC) && !lookup(STT_NOTYPE)) ||
symbol_info.address == nullptr) {
// Unexpected: VDSO is present, yet the expected symbol is missing
// or null.

Loading…
Cancel
Save