[PATCH] D14283: [tsan] Allow memchr interceptor to be used before initialization on OS X
Kuba Brecka via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 3 07:31:21 PST 2015
kubabrecka updated this revision to Diff 39062.
kubabrecka added a comment.
Updating patch.
http://reviews.llvm.org/D14283
Files:
lib/sanitizer_common/sanitizer_common_interceptors.inc
Index: lib/sanitizer_common/sanitizer_common_interceptors.inc
===================================================================
--- lib/sanitizer_common/sanitizer_common_interceptors.inc
+++ lib/sanitizer_common/sanitizer_common_interceptors.inc
@@ -441,6 +441,8 @@
#if SANITIZER_INTERCEPT_MEMCHR
INTERCEPTOR(void*, memchr, const void *s, int c, SIZE_T n) {
+ if (COMMON_INTERCEPTOR_NOTHING_IS_INITIALIZED)
+ return internal_memchr(s, c, n);
void *ctx;
COMMON_INTERCEPTOR_ENTER(ctx, memchr, s, c, n);
void *res = REAL(memchr)(s, c, n);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D14283.39062.patch
Type: text/x-patch
Size: 555 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151103/e544af91/attachment.bin>
More information about the llvm-commits
mailing list