From c2eb17db3750ebf0c2e0021ed9b5a58b46b9d478 Mon Sep 17 00:00:00 2001 From: Kostya Serebryany Date: Fri, 22 Apr 2016 23:27:15 +0000 Subject: [PATCH] [sanitizer] revert r267203 as it breaks aarch64 bots llvm-svn: 267251 --- compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cc b/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cc index 20aed19..6c1a852 100644 --- a/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cc +++ b/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cc @@ -272,8 +272,7 @@ void *MmapFixedNoReserve(uptr fixed_addr, uptr size, const char *name) { void *MmapNoAccess(uptr fixed_addr, uptr size, const char *name) { int fd = name ? GetNamedMappingFd(name, size) : -1; - unsigned flags = MAP_PRIVATE | MAP_NORESERVE; - if (fixed_addr != 0) flags |= MAP_FIXED; + unsigned flags = MAP_PRIVATE | MAP_FIXED | MAP_NORESERVE; if (fd == -1) flags |= MAP_ANON; return (void *)internal_mmap((void *)fixed_addr, size, PROT_NONE, flags, fd, -- 2.7.4