diff options
author | Roland McGrath <roland@gnu.org> | 2015-10-18 10:33:37 +0000 |
---|---|---|
committer | Iain Sandoe <iains@gcc.gnu.org> | 2015-10-18 10:33:37 +0000 |
commit | efd40fc4161967fa7e0503f12162c8b28c85d632 (patch) | |
tree | 5fc208bc3baf41e825404c97445ff45b58f1f042 /libiberty/pex-unix.c | |
parent | 37341412a50d7389802039e1890df3dca717b9db (diff) | |
download | gcc-efd40fc4161967fa7e0503f12162c8b28c85d632.zip gcc-efd40fc4161967fa7e0503f12162c8b28c85d632.tar.gz gcc-efd40fc4161967fa7e0503f12162c8b28c85d632.tar.bz2 |
Fix PR63758 by using the _NSGetEnviron() API on Darwin
include/
Roland McGrath <roland@gnu.org>
PR other/63758
* environ.h: New file.
libiberty/
Roland McGrath <roland@gnu.org>
Iain Sandoe <iain@codesourcery.com>
PR other/63758
* pex-unix.c: Obtain the environment interface from settings in environ.h
rather than in-line code. Update copyright date.
* setenv.c: Likewise.
* xmalloc.c: Likewise.
Co-Authored-By: Iain Sandoe <iain@codesourcery.com>
From-SVN: r228942
Diffstat (limited to 'libiberty/pex-unix.c')
-rw-r--r-- | libiberty/pex-unix.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/libiberty/pex-unix.c b/libiberty/pex-unix.c index 0715115..b48f315 100644 --- a/libiberty/pex-unix.c +++ b/libiberty/pex-unix.c @@ -2,7 +2,7 @@ with other subprocesses), and wait for it. Generic Unix version (also used for UWIN and VMS). Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2009, - 2010 Free Software Foundation, Inc. + 2010, 2015 Free Software Foundation, Inc. This file is part of the libiberty library. Libiberty is free software; you can redistribute it and/or @@ -23,6 +23,7 @@ Boston, MA 02110-1301, USA. */ #include "config.h" #include "libiberty.h" #include "pex-common.h" +#include "environ.h" #include <stdio.h> #include <signal.h> @@ -390,8 +391,6 @@ pex_child_error (struct pex_obj *obj, const char *executable, /* Execute a child. */ -extern char **environ; - #if defined(HAVE_SPAWNVE) && defined(HAVE_SPAWNVPE) /* Implementation of pex->exec_child using the Cygwin spawn operation. */ |