Skip to content

Commit b995576

Browse files
committedJan 22, 2024
posix_spawn: always compute envp
posix_spawn doesn't inherit any env, so we need to always pass it all.
1 parent 10988dc commit b995576

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed
 

‎process.c

+2
Original file line numberDiff line numberDiff line change
@@ -372,6 +372,8 @@ static rb_pid_t cached_pid;
372372
#define execv(path, argv) (rb_async_bug_errno("unreachable: async-signal-unsafe execv() is called", 0))
373373
#define execl(path, arg0, arg1, arg2, term) do { extern char **environ; execle((path), (arg0), (arg1), (arg2), (term), (environ)); } while (0)
374374
#define ALWAYS_NEED_ENVP 1
375+
#elif defined(HAVE_POSIX_SPAWN)
376+
#define ALWAYS_NEED_ENVP 1
375377
#else
376378
#define ALWAYS_NEED_ENVP 0
377379
#endif

0 commit comments

Comments
 (0)
Failed to load comments.