forked from OSchip/llvm-project
tsan: fix strerror interceptor (eliminate false positives)
llvm-svn: 193070
This commit is contained in:
parent
ac42b75195
commit
1e995d4f3e
|
@ -1831,7 +1831,7 @@ INTERCEPTOR(char *, strerror, int errnum) {
|
||||||
COMMON_INTERCEPTOR_ENTER(ctx, strerror, errnum);
|
COMMON_INTERCEPTOR_ENTER(ctx, strerror, errnum);
|
||||||
char *res = REAL(strerror)(errnum);
|
char *res = REAL(strerror)(errnum);
|
||||||
if (res)
|
if (res)
|
||||||
COMMON_INTERCEPTOR_WRITE_RANGE(ctx, res, REAL(strlen)(res) + 1);
|
COMMON_INTERCEPTOR_INITIALIZE_RANGE(ctx, res, REAL(strlen)(res) + 1);
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
#define INIT_STRERROR INTERCEPT_FUNCTION(strerror);
|
#define INIT_STRERROR INTERCEPT_FUNCTION(strerror);
|
||||||
|
|
Loading…
Reference in New Issue