[ASan] don't call strerr from functions that map memory, since this results in malloc().
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@176800 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/sanitizer_common/sanitizer_posix.cc b/lib/sanitizer_common/sanitizer_posix.cc
index 001ca75..773f376 100644
--- a/lib/sanitizer_common/sanitizer_posix.cc
+++ b/lib/sanitizer_common/sanitizer_posix.cc
@@ -66,8 +66,8 @@
Die();
}
recursion_count++;
- Report("ERROR: %s failed to allocate 0x%zx (%zd) bytes of %s: %s\n",
- SanitizerToolName, size, size, mem_type, strerror(errno));
+ Report("ERROR: %s failed to allocate 0x%zx (%zd) bytes of %s: %d\n",
+ SanitizerToolName, size, size, mem_type, errno);
DumpProcessMap();
CHECK("unable to mmap" && 0);
}