[compiler-rt] [compiler-rt] safestack fix (old ?) solaris build. (PR #97178)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Jun 29 12:29:22 PDT 2024
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff ddaa93b095288ce459be4096193c40a4ea247b11 7b3e22cfa977ed46c98e7e78ade19b72565ee4d2 -- compiler-rt/lib/safestack/safestack_platform.h
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/compiler-rt/lib/safestack/safestack_platform.h b/compiler-rt/lib/safestack/safestack_platform.h
index 0a16e13f7b..d4b2e2ef73 100644
--- a/compiler-rt/lib/safestack/safestack_platform.h
+++ b/compiler-rt/lib/safestack/safestack_platform.h
@@ -91,11 +91,11 @@ inline int TgKill(pid_t pid, ThreadId tid, int sig) {
(void)pid;
return _REAL(_lwp_kill, tid, sig);
#elif SANITIZER_SOLARIS
-# ifdef SYS_lwp_kill
+# ifdef SYS_lwp_kill
return syscall(SYS_lwp_kill, tid, sig);
-# else
+# else
return -1;
-# endif
+# endif
#elif SANITIZER_FREEBSD
return syscall(SYS_thr_kill2, pid, tid, sig);
#else
@@ -110,7 +110,8 @@ inline void *Mmap(void *addr, size_t length, int prot, int flags, int fd,
#elif SANITIZER_FREEBSD && (defined(__aarch64__) || defined(__x86_64__))
return (void *)__syscall(SYS_mmap, addr, length, prot, flags, fd, offset);
#elif SANITIZER_SOLARIS
- return (void *)(uintptr_t)syscall(SYS_mmap, addr, length, prot, flags, fd, offset);
+ return (void *)(uintptr_t)syscall(SYS_mmap, addr, length, prot, flags, fd,
+ offset);
#else
return (void *)syscall(SYS_mmap, addr, length, prot, flags, fd, offset);
#endif
``````````
</details>
https://github.com/llvm/llvm-project/pull/97178
More information about the llvm-commits
mailing list