#include "virt.h"
#include "watchdog.h"
+#if HAS_FEATURE_ADDRESS_SANITIZER
+#include <sanitizer/lsan_interface.h>
+#endif
+
static enum {
ACTION_RUN,
ACTION_HELP,
}
#endif
+#if HAS_FEATURE_ADDRESS_SANITIZER
+ __lsan_do_leak_check();
+#endif
+
if (shutdown_verb) {
r = become_shutdown(shutdown_verb, retval);
log_error_errno(r, "Failed to execute shutdown binary, %s: %m", getpid_cached() == 1 ? "freezing" : "quitting");
After=multi-user.target
[Service]
-ExecStart=/bin/sh -x -c 'systemctl --state=failed --no-legend --no-pager > /failed ; echo OK > /testok'
+ExecStart=/bin/sh -x -c 'systemctl --state=failed --no-legend --no-pager > /failed ; systemctl daemon-reload ; echo OK > /testok'
Type=oneshot
EOF
ls -l $TESTDIR/journal/*/*.journal
test -s $TESTDIR/failed && ret=$(($ret+1))
[ -n "$TIMED_OUT" ] && ret=$(($ret+1))
+ if [[ "$IS_BUILT_WITH_ASAN" = "yes" ]]; then
+ ls -l "$TESTDIR/$1"
+ if [[ -e "$TESTDIR/$1/systemd.asan.log.1" ]]; then
+ cat "$TESTDIR/$1/systemd.asan.log.1"
+ ret=$(($ret+1))
+ fi
+ fi
+
return $ret
}