summaryrefslogtreecommitdiff
path: root/lib/sanitizer_common/sanitizer_procmaps.h
diff options
context:
space:
mode:
authorEvgeniy Stepanov <eugeni.stepanov@gmail.com>2019-01-08 01:07:34 +0000
committerEvgeniy Stepanov <eugeni.stepanov@gmail.com>2019-01-08 01:07:34 +0000
commit726dd54e7c60bc1d3e39f200dbae537c7d3cc612 (patch)
treea895a730c2ad9bec44ea51ac39e67e523c0fb5a0 /lib/sanitizer_common/sanitizer_procmaps.h
parent8ebc3668b07fc5cca6010265cd4795443f1c1bea (diff)
downloadcompiler-rt-726dd54e7c60bc1d3e39f200dbae537c7d3cc612.tar.gz
[asan] Support running without /proc
Summary: This patch lets ASan run when /proc is not accessible (ex. not mounted yet). It includes a special test-only flag that emulates this condition in an unpriviledged process. This only matters on Linux, where /proc is necessary to enumerate virtual memory mappings. Reviewers: vitalybuka, pcc, krytarowski Subscribers: kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D56141 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@350590 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/sanitizer_common/sanitizer_procmaps.h')
-rw-r--r--lib/sanitizer_common/sanitizer_procmaps.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/sanitizer_common/sanitizer_procmaps.h b/lib/sanitizer_common/sanitizer_procmaps.h
index 9fde040a1..acb7104f3 100644
--- a/lib/sanitizer_common/sanitizer_procmaps.h
+++ b/lib/sanitizer_common/sanitizer_procmaps.h
@@ -70,6 +70,7 @@ class MemoryMappingLayout {
explicit MemoryMappingLayout(bool cache_enabled);
~MemoryMappingLayout();
bool Next(MemoryMappedSegment *segment);
+ bool Error() const;
void Reset();
// In some cases, e.g. when running under a sandbox on Linux, ASan is unable
// to obtain the memory mappings. It should fall back to pre-cached data