From dd9e14ea78d71df83982cd9ad8852d804c6350a9 Mon Sep 17 00:00:00 2001 From: 30025988 Date: Thu, 10 Aug 2023 16:37:53 +0800 Subject: [PATCH] fix on ReExec implementation for tsan under linux_arm environment --- libsanitizer/sanitizer_common/sanitizer_linux_libcdep.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libsanitizer/sanitizer_common/sanitizer_linux_libcdep.cpp b/libsanitizer/sanitizer_common/sanitizer_linux_libcdep.cpp index 2720a3cab2c9b..4db9c46f1889b 100644 --- a/libsanitizer/sanitizer_common/sanitizer_linux_libcdep.cpp +++ b/libsanitizer/sanitizer_common/sanitizer_linux_libcdep.cpp @@ -969,8 +969,8 @@ void ReExec() { // rely on that will fail to load shared libraries. Query AT_EXECFN instead. pathname = reinterpret_cast(getauxval(AT_EXECFN)); #endif - - uptr rv = internal_execve(pathname, GetArgv(), GetEnviron()); + char **argv = GetArgv(); + uptr rv = internal_execve(argv[0], argv, GetEnviron()); int rverrno; CHECK_EQ(internal_iserror(rv, &rverrno), true); Printf("execve failed, errno %d\n", rverrno);