[compiler-rt] r217156 - Intercept _exit() for sanitizers' needs on FreeBSD
Viktor Kutuzov
vkutuzov at accesssoftek.com
Thu Sep 4 07:24:27 PDT 2014
Author: vkutuzov
Date: Thu Sep 4 09:24:27 2014
New Revision: 217156
URL: http://llvm.org/viewvc/llvm-project?rev=217156&view=rev
Log:
Intercept _exit() for sanitizers' needs on FreeBSD
Differential Revision: http://reviews.llvm.org/D5171
Modified:
compiler-rt/trunk/lib/sanitizer_common/sanitizer_platform_interceptors.h
Modified: compiler-rt/trunk/lib/sanitizer_common/sanitizer_platform_interceptors.h
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/sanitizer_common/sanitizer_platform_interceptors.h?rev=217156&r1=217155&r2=217156&view=diff
==============================================================================
--- compiler-rt/trunk/lib/sanitizer_common/sanitizer_platform_interceptors.h (original)
+++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_platform_interceptors.h Thu Sep 4 09:24:27 2014
@@ -29,6 +29,12 @@
# define SI_LINUX_NOT_ANDROID 0
#endif
+#if SANITIZER_FREEBSD
+# define SI_FREEBSD 1
+#else
+# define SI_FREEBSD 0
+#endif
+
#if SANITIZER_LINUX
# define SI_LINUX 1
#else
@@ -196,7 +202,7 @@
// FIXME: getline seems to be available on OSX 10.7
#define SANITIZER_INTERCEPT_GETLINE SI_LINUX_NOT_ANDROID
-#define SANITIZER_INTERCEPT__EXIT SI_LINUX
+#define SANITIZER_INTERCEPT__EXIT SI_LINUX || SI_FREEBSD
#define SANITIZER_INTERCEPT_PHTREAD_MUTEX SI_NOT_WINDOWS
#define SANITIZER_INTERCEPT_PTHREAD_SETNAME_NP SI_LINUX_NOT_ANDROID
More information about the llvm-commits
mailing list