diff options
author | James McCoy <jamessan@jamessan.com> | 2021-01-31 07:49:31 -0500 |
---|---|---|
committer | James McCoy <jamessan@jamessan.com> | 2021-01-31 07:54:22 -0500 |
commit | 035ee868ae2d9cbbf2a290ca3412946fade20833 (patch) | |
tree | b9cbbcd2887714a1b250bf06acf1588a837bbc8f /src/nvim/os/pty_process_unix.c | |
parent | db734ae99463c498309bc8830f902fb65c6523f3 (diff) | |
download | rneovim-035ee868ae2d9cbbf2a290ca3412946fade20833.tar.gz rneovim-035ee868ae2d9cbbf2a290ca3412946fade20833.tar.bz2 rneovim-035ee868ae2d9cbbf2a290ca3412946fade20833.zip |
fix(pty_proc/macOS): Properly set the environment for the child
Binding _NSGetEnviron()'s return value to a local variable and then
re-binding that is incorrect. We need to directly update what
_NSGetEnviron() refers to.
Diffstat (limited to 'src/nvim/os/pty_process_unix.c')
-rw-r--r-- | src/nvim/os/pty_process_unix.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/os/pty_process_unix.c b/src/nvim/os/pty_process_unix.c index 0733589870..348a139e79 100644 --- a/src/nvim/os/pty_process_unix.c +++ b/src/nvim/os/pty_process_unix.c @@ -159,7 +159,7 @@ static void init_child(PtyProcess *ptyproc) FUNC_ATTR_NONNULL_ALL { #if defined(HAVE__NSGETENVIRON) - char **environ = *_NSGetEnviron(); +#define environ (*_NSGetEnviron()) #else extern char **environ; #endif |