[PATCH] D117051: [sanitizer_common] Only use NT_GNU_BUILD_ID in sanitizer_linux_libcdep.cpp if supported
Rainer Orth via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 11 14:51:29 PST 2022
This revision was automatically updated to reflect the committed changes.
Closed by commit rGc79d37279156: [sanitizer_common] Only use NT_GNU_BUILD_ID in sanitizer_linux_libcdep.cpp if… (authored by ro).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D117051/new/
https://reviews.llvm.org/D117051
Files:
compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp
Index: compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp
===================================================================
--- compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp
+++ compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp
@@ -604,6 +604,7 @@
cur_module.addAddressRange(cur_beg, cur_end, executable,
writable);
} else if (phdr->p_type == PT_NOTE) {
+# ifdef NT_GNU_BUILD_ID
uptr off = 0;
while (off + sizeof(ElfW(Nhdr)) < phdr->p_memsz) {
auto *nhdr = reinterpret_cast<const ElfW(Nhdr) *>(info->dlpi_addr +
@@ -629,6 +630,7 @@
off += sizeof(*nhdr) + RoundUpTo(nhdr->n_namesz, 4) +
RoundUpTo(nhdr->n_descsz, 4);
}
+# endif
}
}
modules->push_back(cur_module);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D117051.399090.patch
Type: text/x-patch
Size: 815 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220111/a1695bb7/attachment.bin>
More information about the llvm-commits
mailing list