|
From: Mark W. <ma...@so...> - 2021-02-11 17:41:52
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=208f2d96069574e7a75cb3f8e53adb216e4795b9 commit 208f2d96069574e7a75cb3f8e53adb216e4795b9 Author: Mark Wielaard <ma...@kl...> Date: Thu Feb 11 18:29:52 2021 +0100 vg_regtest: test-specific environment variables not reset between tests Test-specific environment variables set in .vgtest files are not reset between tests. This can result in tests running with environment variables intended for a previously run test. This can be easily fixed by clearing the @env and @envB arrays in tests/vg_regtest:read_vgtest_file() Original patch by Aaron Merey <am...@re...> https://bugs.kde.org/show_bug.cgi?id=432672 Diff: --- NEWS | 1 + tests/vg_regtest.in | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index cd372235f2..3e0f5a0bd3 100644 --- a/NEWS +++ b/NEWS @@ -87,6 +87,7 @@ n-i-bz helgrind: If hg_cli__realloc fails, return NULL. diagnostics 430354 ppc stxsibx and stxsihx instructions write too much data 430485 expr_is_guardable doesn't handle Iex_Qop +432672 vg_regtest: test-specific environment variables not reset between tests Release 3.16.1 (?? June 2020) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/tests/vg_regtest.in b/tests/vg_regtest.in index 5803b86f59..c7cc60124b 100755 --- a/tests/vg_regtest.in +++ b/tests/vg_regtest.in @@ -300,9 +300,9 @@ sub read_vgtest_file($) my ($f) = @_; # Defaults. - ($vgopts, $prog, $args) = ("", undef, ""); + ($vgopts, $prog, $args, @env) = ("", undef, "", ()); ($stdout_filter, $stderr_filter) = (undef, undef); - ($progB, $argsB, $stdinB) = (undef, "", undef); + ($progB, $argsB, $stdinB, @envB) = (undef, "", undef, ()); ($stdoutB_filter, $stderrB_filter) = (undef, undef); ($prereq, $post, $cleanup) = (undef, undef, undef); ($stdout_filter_args, $stderr_filter_args) = (undef, undef); |