From: David Mulder Date: Tue, 13 Feb 2018 15:35:12 +0000 (-0700) Subject: python: Write py3 bin to correct args location X-Git-Tag: talloc-2.1.13~37 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=0210f60759c90e22fe86738490b328df7ff23b6f;p=thirdparty%2Fsamba.git python: Write py3 bin to correct args location Comands written like this were working: python /home/dmulder/code/samba/source4/scripting/bin/subunitrun Changed to: /usr/bin/python3 /home/dmulder/code/samba/source4/scripting/bin/subunitrun But commands with env args overwrite the wrong arg: CLIENT_IP=127.0.0.11 SOCKET_WRAPPER_DEFAULT_IFACE=11 python /home/dmulder/code/samba/source4/scripting/bin/subunitrun Changed to: /usr/bin/python3 SOCKET_WRAPPER_DEFAULT_IFACE=11 python /home/dmulder/code/samba/source4/scripting/bin/subunitrun And were further mangled in plantestsuite_loadlist() to: /usr/bin/python3 /home/dmulder/code/samba/source4/scripting/bin/subunitrun SOCKET_WRAPPER_DEFAULT_IFACE=11 python /home/dmulder/code/samba/source4/scripting/bin/subunitrun Signed-off-by: David Mulder Reviewed-by: Andrew Bartlett Reviewed-by: Douglas Bagnall --- diff --git a/source4/selftest/tests.py b/source4/selftest/tests.py index 660a75fb927..0f32c6deed1 100755 --- a/source4/selftest/tests.py +++ b/source4/selftest/tests.py @@ -570,7 +570,7 @@ def planoldpythontestsuite(env, module, name=None, extra_path=[], environ={}, ex name = module plantestsuite_loadlist(name, env, args) if py3_compatible and extra_python is not None: - args[0] = subunitrun3 + args[args.index(subunitrun)] = subunitrun3 plantestsuite_loadlist(name, env, args)