From 4dc76eb770121720db12be1ec83ff13ee4f53dbf Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Thu, 30 May 2024 10:22:51 +0200 Subject: [PATCH] test-execute: Skip test_exec_mount_apivfs() when running with sanitizers The test fails when running under sanitizers due to missing sanitizer libraries. For now, let's skip the test until we can make the necessary changes to run it under sanitizers. --- src/test/test-execute.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/test/test-execute.c b/src/test/test-execute.c index 191741d97c..daddeb61d0 100644 --- a/src/test/test-execute.c +++ b/src/test/test-execute.c @@ -615,6 +615,7 @@ static void test_exec_inaccessiblepaths(Manager *m) { test(m, "exec-inaccessiblepaths-mount-propagation.service", can_unshare ? 0 : MANAGER_IS_SYSTEM(m) ? EXIT_FAILURE : EXIT_NAMESPACE, CLD_EXITED); } +#if !HAS_FEATURE_ADDRESS_SANITIZER static int on_spawn_io(sd_event_source *s, int fd, uint32_t revents, void *userdata) { char **result = userdata; char buf[4096]; @@ -754,8 +755,10 @@ static int find_libraries(const char *exec, char ***ret) { *ret = TAKE_PTR(libraries); return 0; } +#endif static void test_exec_mount_apivfs(Manager *m) { +#if !HAS_FEATURE_ADDRESS_SANITIZER _cleanup_free_ char *fullpath_touch = NULL, *fullpath_test = NULL, *data = NULL; _cleanup_strv_free_ char **libraries = NULL, **libraries_test = NULL; int r; @@ -801,6 +804,7 @@ static void test_exec_mount_apivfs(Manager *m) { test(m, "exec-mount-apivfs-no.service", can_unshare || !MANAGER_IS_SYSTEM(m) ? 0 : EXIT_NAMESPACE, CLD_EXITED); (void) rm_rf("/tmp/test-exec-mount-apivfs-no/root", REMOVE_ROOT|REMOVE_PHYSICAL); +#endif } static void test_exec_noexecpaths(Manager *m) { -- 2.25.1