diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-04-04 01:00:49 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-04-04 01:00:49 +0000 |
commit | 9c64c3ed5c45084e62f46fc6b5d80948697c3f86 (patch) | |
tree | d8aadd52008d8bd4c927990893260b607f7d095d /io.c | |
parent | 9ce7494cda368d85701058cea950912b5eeea237 (diff) | |
download | ruby-9c64c3ed5c45084e62f46fc6b5d80948697c3f86.tar.gz |
* io.c (popen_exec): should not close close-on-exec FDs.
[ruby-dev:30679]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -3040,6 +3040,9 @@ popen_exec(void *pp) popen_redirect(p); for (fd = 3; fd < NOFILE; fd++) { +#ifdef FD_CLOEXEC + if (fcntl(fd, F_GETFD) & FD_CLOEXEC) continue; +#endif close(fd); } return rb_exec(&p->exec); |