summaryrefslogtreecommitdiff
path: root/src/libstddjb/child_spawn1_internal.c
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2017-12-22 16:44:47 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2017-12-22 16:44:47 +0000
commita8e40d0287f05f6e444035431b1cc7b340fe8d79 (patch)
tree3d34decfcdfed87f14ab6b467dfd8ca3c7add471 /src/libstddjb/child_spawn1_internal.c
parent8cd0d07171f8b32553ef0c6936fd5737adcb4bab (diff)
downloadskalibs-a8e40d0287f05f6e444035431b1cc7b340fe8d79.tar.xz
Deprecate env_get
Diffstat (limited to 'src/libstddjb/child_spawn1_internal.c')
-rw-r--r--src/libstddjb/child_spawn1_internal.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libstddjb/child_spawn1_internal.c b/src/libstddjb/child_spawn1_internal.c
index eea4f09..38a6e60 100644
--- a/src/libstddjb/child_spawn1_internal.c
+++ b/src/libstddjb/child_spawn1_internal.c
@@ -3,7 +3,6 @@
#include <skalibs/sysdeps.h>
#include <unistd.h>
#include <errno.h>
-#include <skalibs/djbunix.h>
#ifdef SKALIBS_HASPOSIXSPAWN
@@ -11,7 +10,7 @@
#include <spawn.h>
#include <stdlib.h>
#include <skalibs/config.h>
-#include <skalibs/env.h>
+#include <skalibs/djbunix.h>
pid_t child_spawn1_internal (char const *prog, char const *const *argv, char const *const *envp, int *p, int to)
{
@@ -19,7 +18,7 @@ pid_t child_spawn1_internal (char const *prog, char const *const *argv, char con
posix_spawnattr_t attr ;
int e ;
pid_t pid ;
- int haspath = !!env_get("PATH") ;
+ int haspath = !!getenv("PATH") ;
if (coe(p[!(to & 1)]) < 0) { e = errno ; goto err ; }
e = posix_spawnattr_init(&attr) ;
if (e) goto err ;
@@ -69,6 +68,7 @@ pid_t child_spawn1_internal (char const *prog, char const *const *argv, char con
#include <skalibs/allreadwrite.h>
#include <skalibs/strerr2.h>
#include <skalibs/sig.h>
+#include <skalibs/djbunix.h>
pid_t child_spawn1_internal (char const *prog, char const *const *argv, char const *const *envp, int *p, int to)
{