]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test: set $ASAN_RT_PATH along with $LD_PRELOAD to the ASan runtime DSO
authorFrantisek Sumsal <frantisek@sumsal.cz>
Mon, 6 Jun 2022 12:45:11 +0000 (14:45 +0200)
committerFrantisek Sumsal <frantisek@sumsal.cz>
Mon, 6 Jun 2022 12:45:11 +0000 (14:45 +0200)
Since we unset $LD_PRELOAD in the testsuite-* units (due to another
issue), let's store the path to the ASan DSO in another env variable, so
we can easily access it in the testsuite scripts when needed.

test/test-functions

index a7026d7ad7b8960e0516553ce1f1799802dbb297..1459ee1456dd670dc4230eb462b43b56ab876a61 100644 (file)
@@ -832,7 +832,7 @@ mount -o remount,rw /
 
 # A lot of services (most notably dbus) won't start without preloading libasan
 # See https://github.com/systemd/systemd/issues/5004
-DEFAULT_ENVIRONMENT="\$DEFAULT_ENVIRONMENT LD_PRELOAD=$ASAN_RT_PATH"
+DEFAULT_ENVIRONMENT="\$DEFAULT_ENVIRONMENT LD_PRELOAD=$ASAN_RT_PATH ASAN_RT_PATH=$ASAN_RT_PATH"
 
 if [[ "$ASAN_COMPILER" == "clang" ]]; then
   # Let's add the ASan DSO's path to the dynamic linker's cache. This is pretty