summary refs log tree commit diff
path: root/support
diff options
context:
space:
mode:
authorSiddhesh Poyarekar <siddhesh@sourceware.org>2021-03-15 17:23:30 +0530
committerSiddhesh Poyarekar <siddhesh@sourceware.org>2021-03-16 19:06:36 +0530
commite958490f8c74e660bd93c128b3bea746e268f3f6 (patch)
tree210551c8fdd8748b34f3b48d73b70095b8bd2153 /support
parentc82e691c561433b0f94615d2172add16dd59bcfb (diff)
downloadglibc-e958490f8c74e660bd93c128b3bea746e268f3f6.tar.gz
glibc-e958490f8c74e660bd93c128b3bea746e268f3f6.tar.xz
glibc-e958490f8c74e660bd93c128b3bea746e268f3f6.zip
support: Pass environ to child process
Pass environ to posix_spawn so that the child process can inherit
environment of the test.
Diffstat (limited to 'support')
-rw-r--r--support/support_subprocess.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/support/support_subprocess.c b/support/support_subprocess.c
index 838eda96ff..2acfc57b7e 100644
--- a/support/support_subprocess.c
+++ b/support/support_subprocess.c
@@ -84,7 +84,7 @@ support_subprogram (const char *file, char *const argv[])
   xposix_spawn_file_actions_addclose (&fa, result.stdout_pipe[1]);
   xposix_spawn_file_actions_addclose (&fa, result.stderr_pipe[1]);
 
-  result.pid = xposix_spawn (file, &fa, NULL, argv, NULL);
+  result.pid = xposix_spawn (file, &fa, NULL, argv, environ);
 
   xclose (result.stdout_pipe[1]);
   xclose (result.stderr_pipe[1]);