[compiler-rt] [compiler-rt] Remove duplicates of sanitizer_common functions (PR #106488)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 28 22:13:55 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 55cdb3c785ad688054493bb82c0cf3b9d7ccea07 ee8bac1d7b95513c0864793e7740c3a8c71d6190 --extensions cpp -- compiler-rt/lib/interception/interception_win.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/compiler-rt/lib/interception/interception_win.cpp b/compiler-rt/lib/interception/interception_win.cpp
index fbcd8b9f5c..0a9f2b62a7 100644
--- a/compiler-rt/lib/interception/interception_win.cpp
+++ b/compiler-rt/lib/interception/interception_win.cpp
@@ -234,7 +234,7 @@ static bool FunctionHasPadding(uptr address, uptr size) {
}
static void WritePadding(uptr from, uptr size) {
- internal_memset((void*)from, 0xCC, (size_t)size);
+ internal_memset((void *)from, 0xCC, (size_t)size);
}
static void WriteJumpInstruction(uptr from, uptr target) {
@@ -706,7 +706,7 @@ static bool CopyInstructions(uptr to, uptr from, size_t size) {
if (!instruction_size)
return false;
internal_memcpy((void *)(to + cursor), (void *)(from + cursor),
- (size_t)instruction_size);
+ (size_t)instruction_size);
if (rel_offset) {
# if SANITIZER_WINDOWS64
// we want to make sure that the new relative offset still fits in 32-bits
@@ -1013,7 +1013,7 @@ uptr InternalGetProcAddress(void *module, const char *func_name) {
internal_memcpy(function_name, func, funtion_name_length);
function_name[funtion_name_length] = '\0';
- char* separator = internal_strchr(function_name, '.');
+ char *separator = internal_strchr(function_name, '.');
if (!separator)
InterceptionFailed();
*separator = '\0';
``````````
</details>
https://github.com/llvm/llvm-project/pull/106488
More information about the llvm-commits
mailing list