From 5fc86a865cdcec0903ee526366e02af861d0c856 Mon Sep 17 00:00:00 2001 From: Sebastian Wick Date: Thu, 1 Aug 2024 21:32:30 +0200 Subject: [PATCH] tests: Add an address sanitizer suppression file There are two places where we deliberately leak some memory. There are some cases which look like leaks in libostree but it's not impossible that we made a mistake in flatpak. Two other cases seem like issues in flatpak that I couldn't figure out. --- tests/flatpak-asan.supp | 10 ++++++++++ tests/meson.build | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 tests/flatpak-asan.supp diff --git a/tests/flatpak-asan.supp b/tests/flatpak-asan.supp new file mode 100644 index 00000000..b7c1a8b5 --- /dev/null +++ b/tests/flatpak-asan.supp @@ -0,0 +1,10 @@ +# GOnce, deliberately leaking once per process +leak:flatpak_get_user_base_dir_location +leak:flatpak_get_system_default_base_dir_location +# external (libostree) +leak:static_delta_part_execute_thread +leak:_ostree_static_delta_part_open +# Bugs in our code +# Take a look at them and try to figure out what's going on! +leak:flatpak_authenticator_request_proxy_new_for_bus_sync +leak:flatpak_authenticator_proxy_new_for_bus_sync diff --git a/tests/meson.build b/tests/meson.build index eedd710c..9d3a5c86 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -37,7 +37,7 @@ tests_environment_prepend = { 'PATH' : project_build_root / 'app', } -lsan_options = 'log_threads=1' +lsan_options = 'log_threads=1:suppressions=' + meson.current_source_dir() / 'flatpak-asan.supp' if get_option('installed_tests') configure_file(