diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2024-01-10 00:59:52 -0700 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2024-01-10 01:00:37 -0700 |
| commit | 854b88fda0dc6e92399c27f819bb2a0f5c090eb9 (patch) | |
| tree | 519ea4302d30255d6ca79337cc326261f4058a14 /lib/tsan/interception/interception_linux.cpp | |
| parent | 036e9fd479219ed1116fed8c0da89fa5a2829cf9 (diff) | |
| download | zig-854b88fda0dc6e92399c27f819bb2a0f5c090eb9.tar.gz zig-854b88fda0dc6e92399c27f819bb2a0f5c090eb9.zip | |
tsan: update rtl files to LLVM 17.0.6
Diffstat (limited to 'lib/tsan/interception/interception_linux.cpp')
| -rw-r--r-- | lib/tsan/interception/interception_linux.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/lib/tsan/interception/interception_linux.cpp b/lib/tsan/interception/interception_linux.cpp index 5111a87f0a..ef8136eb4f 100644 --- a/lib/tsan/interception/interception_linux.cpp +++ b/lib/tsan/interception/interception_linux.cpp @@ -33,7 +33,7 @@ static int StrCmp(const char *s1, const char *s2) { } #endif -static void *GetFuncAddr(const char *name, uptr wrapper_addr) { +static void *GetFuncAddr(const char *name, uptr trampoline) { #if SANITIZER_NETBSD // FIXME: Find a better way to handle renames if (StrCmp(name, "sigaction")) @@ -50,17 +50,17 @@ static void *GetFuncAddr(const char *name, uptr wrapper_addr) { // In case `name' is not loaded, dlsym ends up finding the actual wrapper. // We don't want to intercept the wrapper and have it point to itself. - if ((uptr)addr == wrapper_addr) + if ((uptr)addr == trampoline) addr = nullptr; } return addr; } bool InterceptFunction(const char *name, uptr *ptr_to_real, uptr func, - uptr wrapper) { - void *addr = GetFuncAddr(name, wrapper); + uptr trampoline) { + void *addr = GetFuncAddr(name, trampoline); *ptr_to_real = (uptr)addr; - return addr && (func == wrapper); + return addr && (func == trampoline); } // dlvsym is a GNU extension supported by some other platforms. @@ -70,12 +70,12 @@ static void *GetFuncAddr(const char *name, const char *ver) { } bool InterceptFunction(const char *name, const char *ver, uptr *ptr_to_real, - uptr func, uptr wrapper) { + uptr func, uptr trampoline) { void *addr = GetFuncAddr(name, ver); *ptr_to_real = (uptr)addr; - return addr && (func == wrapper); + return addr && (func == trampoline); } -#endif // SANITIZER_GLIBC || SANITIZER_FREEBSD || SANITIZER_NETBSD +# endif // SANITIZER_GLIBC || SANITIZER_FREEBSD || SANITIZER_NETBSD } // namespace __interception |
