Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,12 @@ test-leaks: update-test-discovery CMakeLists.txt
-DCMAKE_RUNTIME_OUTPUT_DIRECTORY=$(PWD)/leak-build \
-DSENTRY_BACKEND=none \
-DWITH_ASAN_OPTION=ON \
-DCMAKE_C_COMPILER=/usr/local/opt/llvm/bin/clang \
-DCMAKE_CXX_COMPILER=/usr/local/opt/llvm/bin/clang++ \
-DCMAKE_LINKER=/usr/local/opt/llvm/bin/clang \
-DCMAKE_C_COMPILER=/opt/homebrew/opt/llvm/bin/clang \
-DCMAKE_CXX_COMPILER=/opt/homebrew/opt/llvm/bin/clang++ \
-DCMAKE_LINKER=/opt/homebrew/opt/llvm/bin/clang \
..
@cmake --build leak-build --target sentry_test_unit --parallel
@ASAN_OPTIONS=detect_leaks=1 ./leak-build/sentry_test_unit
@LSAN_OPTIONS=suppressions=$(PWD)/tests/leaks.txt:print_suppressions=0 ASAN_OPTIONS=detect_leaks=1 ./leak-build/sentry_test_unit
.PHONY: test-leaks

benchmark: setup-venv
Expand Down
14 changes: 13 additions & 1 deletion tests/leaks.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,16 @@ leak:SCDynamicStoreCopyProxiesWithOptions
# I cannot reproduce it with the current brew llvm package (18.1.7). TODO: remove when GHA macOS runner image updates the llvm package.
leak:realizeClassWithoutSwift

leak:Curl_getaddrinfo_ex
leak:Curl_getaddrinfo_ex

# macOS notify framework false positives from fork() during tests.
# The notify framework re-allocates internal data structures in the child
# process after fork(), which LSan reports as leaks since the parent's
# pointers are gone. Upstream: https://github.com/google/sanitizers/issues/764
leak:os_set_*_ptr_init
leak:os_map_*_init

# macOS Objective-C runtime false positive from _fetchInitializingClassList.
# Triggered during lazy class initialization in CoreFoundation/CFNumber.
# Upstream: https://github.com/google/sanitizers/issues/1781
leak:_fetchInitializingClassList
Loading