diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | io.c | 3 |
2 files changed, 8 insertions, 0 deletions
@@ -1,3 +1,8 @@ +Wed Apr 4 10:01:20 2007 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * io.c (popen_exec): should not close close-on-exec FDs. + [ruby-dev:30679] + Tue Apr 4 04:17:18 2007 Technorama Ltd. <oss-ruby@technorama.net> * ext/openssl/ossl_ssl.c: Add documentation. @@ -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); |