summaryrefslogtreecommitdiff
path: root/src/stdbuf.c
diff options
context:
space:
mode:
authorJim Meyering <meyering@fb.com>2015-06-28 10:35:04 -0700
committerJim Meyering <meyering@fb.com>2015-06-29 14:18:59 -0700
commitf303fb6bbb6a924ab47a5c0d855ef27cb234347f (patch)
tree2ea07ddf6e397d5dd7f4d1192eb8d45199aee74f /src/stdbuf.c
parent46416bb7c365e4faf44152dd66094c726dc714c8 (diff)
downloadcoreutils-f303fb6bbb6a924ab47a5c0d855ef27cb234347f.tar.xz
maint: stdbuf.c: avoid the OS X putenv function
* bootstrap.conf (gnulib_modules): Add setenv, to make this module dependency explicit; setenv is also used by split. * src/stdbuf.c (set_LD_PRELOAD) [__APPLE__]: Use the OS X setenv function, rather than putenv, per that documentation: https://developer.apple.com/\ library/mac/documentation/Darwin/Reference/ManPages/man3/putenv.3.html
Diffstat (limited to 'src/stdbuf.c')
-rw-r--r--src/stdbuf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/stdbuf.c b/src/stdbuf.c
index fe4d773a7..116619d7a 100644
--- a/src/stdbuf.c
+++ b/src/stdbuf.c
@@ -256,7 +256,7 @@ set_LD_PRELOAD (void)
ret = putenv (LD_PRELOAD);
#ifdef __APPLE__
if (ret == 0)
- ret = putenv ("DYLD_FORCE_FLAT_NAMESPACE=y");
+ ret = setenv ("DYLD_FORCE_FLAT_NAMESPACE", "y", 1);
#endif
if (ret != 0)