[compiler-rt] [nfc][sanitizer] Unmap memory in test (PR #112644)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 16 18:29:00 PDT 2024
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-compiler-rt-sanitizer
Author: Vitaly Buka (vitalybuka)
<details>
<summary>Changes</summary>
---
Full diff: https://github.com/llvm/llvm-project/pull/112644.diff
1 Files Affected:
- (modified) compiler-rt/lib/sanitizer_common/tests/sanitizer_posix_test.cpp (+2)
``````````diff
diff --git a/compiler-rt/lib/sanitizer_common/tests/sanitizer_posix_test.cpp b/compiler-rt/lib/sanitizer_common/tests/sanitizer_posix_test.cpp
index be577c3364049c..bed19d15a8ec77 100644
--- a/compiler-rt/lib/sanitizer_common/tests/sanitizer_posix_test.cpp
+++ b/compiler-rt/lib/sanitizer_common/tests/sanitizer_posix_test.cpp
@@ -78,6 +78,8 @@ TEST(SanitizerCommon, IsAccessibleMemoryRange) {
EXPECT_TRUE(IsAccessibleMemoryRange(mem + 2 * page_size, page_size));
EXPECT_FALSE(IsAccessibleMemoryRange(mem, 3 * page_size));
EXPECT_FALSE(IsAccessibleMemoryRange(0x0, 2));
+
+ munmap((void *)mem, 3 * page_size);
}
} // namespace __sanitizer
``````````
</details>
https://github.com/llvm/llvm-project/pull/112644
More information about the llvm-commits
mailing list