llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT--> @llvm/pr-subscribers-compiler-rt-sanitizer Author: Michał Górny (mgorny) <details> <summary>Changes</summary> Remove the openat interceptor from the 19.x branch, as it currently breaks builds against fortify-sources glibc, and full rtsan will not be included in this version anyway. Suggested by Chris Apple in https://github.com/llvm/llvm-project/issues/100754#issuecomment-2254169856 Bug #<!-- -->100754 --- Full diff: https://github.com/llvm/llvm-project/pull/100876.diff 2 Files Affected: - (modified) compiler-rt/lib/rtsan/rtsan_interceptors.cpp (-15) - (modified) compiler-rt/lib/rtsan/tests/rtsan_test_interceptors.cpp (-6) ``````````diff diff --git a/compiler-rt/lib/rtsan/rtsan_interceptors.cpp b/compiler-rt/lib/rtsan/rtsan_interceptors.cpp index 4d5423ec629d2..e513d72d95814 100644 --- a/compiler-rt/lib/rtsan/rtsan_interceptors.cpp +++ b/compiler-rt/lib/rtsan/rtsan_interceptors.cpp @@ -69,20 +69,6 @@ INTERCEPTOR(int, open, const char *path, int oflag, ...) { return result; } -INTERCEPTOR(int, openat, int fd, const char *path, int oflag, ...) { - // TODO Establish whether we should intercept here if the flag contains - // O_NONBLOCK - ExpectNotRealtime("openat"); - - va_list args; - va_start(args, oflag); - mode_t mode = va_arg(args, int); - va_end(args); - - const int result = REAL(openat)(fd, path, oflag, mode); - return result; -} - INTERCEPTOR(int, creat, const char *path, mode_t mode) { // TODO Establish whether we should intercept here if the flag contains // O_NONBLOCK @@ -385,7 +371,6 @@ void __rtsan::InitializeInterceptors() { #endif INTERCEPT_FUNCTION(open); - INTERCEPT_FUNCTION(openat); INTERCEPT_FUNCTION(close); INTERCEPT_FUNCTION(fopen); INTERCEPT_FUNCTION(fread); diff --git a/compiler-rt/lib/rtsan/tests/rtsan_test_interceptors.cpp b/compiler-rt/lib/rtsan/tests/rtsan_test_interceptors.cpp index f5b016089087d..a5318a52e45c5 100644 --- a/compiler-rt/lib/rtsan/tests/rtsan_test_interceptors.cpp +++ b/compiler-rt/lib/rtsan/tests/rtsan_test_interceptors.cpp @@ -178,12 +178,6 @@ TEST_F(RtsanFileTest, OpenDiesWhenRealtime) { ExpectNonRealtimeSurvival(func); } -TEST_F(RtsanFileTest, OpenatDiesWhenRealtime) { - auto func = [this]() { openat(0, GetTemporaryFilePath(), O_RDONLY); }; - ExpectRealtimeDeath(func, "openat"); - ExpectNonRealtimeSurvival(func); -} - TEST_F(RtsanFileTest, OpenCreatesFileWithProperMode) { const int mode = S_IRGRP | S_IROTH | S_IRUSR | S_IWUSR; `````````` </details> https://github.com/llvm/llvm-project/pull/100876 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits