1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-08-07 06:43:00 +03:00

support: Add envp argument to support_capture_subprogram

So tests can specify a list of environment variables.
Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>
This commit is contained in:
Adhemerval Zanella
2024-05-06 13:18:47 -03:00
parent c8a0e21da6
commit 1e1ad714ee
16 changed files with 30 additions and 26 deletions

View File

@@ -93,13 +93,14 @@ support_capture_subprocess (void (*callback) (void *), void *closure)
}
struct support_capture_subprocess
support_capture_subprogram (const char *file, char *const argv[])
support_capture_subprogram (const char *file, char *const argv[],
char *const envp[])
{
struct support_capture_subprocess result;
xopen_memstream (&result.out);
xopen_memstream (&result.err);
struct support_subprocess proc = support_subprogram (file, argv);
struct support_subprocess proc = support_subprogram (file, argv, envp);
support_capture_poll (&result, &proc);
return result;