From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2206) id 747FB396E867; Wed, 14 Apr 2021 05:05:11 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 747FB396E867 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Siddhesh Poyarekar To: glibc-cvs@sourceware.org Subject: [glibc/release/2.33/master] support: Pass environ to child process X-Act-Checkin: glibc X-Git-Author: Siddhesh Poyarekar X-Git-Refname: refs/heads/release/2.33/master X-Git-Oldrev: 45b2c57d345092e8a6a9f065a44c9801e09c24c5 X-Git-Newrev: 249c486ce8e80a9e94d51b4bbf3ccf5d0af57e5e Message-Id: <20210414050511.747FB396E867@sourceware.org> Date: Wed, 14 Apr 2021 05:05:11 +0000 (GMT) X-BeenThere: glibc-cvs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Glibc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Apr 2021 05:05:11 -0000 https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=249c486ce8e80a9e94d51b4bbf3ccf5d0af57e5e commit 249c486ce8e80a9e94d51b4bbf3ccf5d0af57e5e Author: Siddhesh Poyarekar Date: Mon Mar 15 17:23:30 2021 +0530 support: Pass environ to child process Pass environ to posix_spawn so that the child process can inherit environment of the test. (cherry picked from commit e958490f8c74e660bd93c128b3bea746e268f3f6) Diff: --- support/support_subprocess.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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]);