diff --git a/meson.build b/meson.build index 83c51366..0c088d16 100644 --- a/meson.build +++ b/meson.build @@ -889,8 +889,6 @@ if get_option('tests') valgrind = find_program('valgrind', required : false) if valgrind.found() - valgrind_env = environment() - valgrind_env.set('CK_FORK', 'no') valgrind_suppressions_file = join_paths(dir_src_test, 'valgrind.suppressions') add_test_setup('valgrind', exe_wrapper : [ valgrind, @@ -898,7 +896,6 @@ if get_option('tests') '--gen-suppressions=all', '--error-exitcode=3', '--suppressions=' + valgrind_suppressions_file ], - env : valgrind_env, timeout_multiplier : 100) else message('valgrind not found, disabling valgrind test suite') diff --git a/test/litest.c b/test/litest.c index b953845a..8504061c 100644 --- a/test/litest.c +++ b/test/litest.c @@ -4184,7 +4184,7 @@ main(int argc, char **argv) int rc; in_debugger = is_debugger_attached(); - if (in_debugger) + if (in_debugger || RUNNING_ON_VALGRIND) setenv("CK_FORK", "no", 0); mode = litest_parse_argv(argc, argv);