summaryrefslogtreecommitdiff
path: root/io.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-06-27 14:14:25 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-06-27 14:14:25 +0000
commit471e41ec70e18339f72539a6331dcf2fb80d2238 (patch)
treeb14eab922eb09349c4016ee8e9591a3d8c7dbd3d /io.c
parent3b989706df0af7d7a3a042cd3470fcee90f208cf (diff)
* string.c: RDoc update for =~ method. a patch from Alex Young
<alex at blackkettle.org>. [ruby-core:08068] * io.c (pipe_open): backout unnecessary fix on 2006-06-26. [ruby-dev:28865] * eval.c (rb_yield_0): exact argument number check now done only for lambda Proc. * eval.c (rb_yield_0): add check for number of arguments, if there's one lambda block parameter. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10412 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r--io.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/io.c b/io.c
index 8927fad927..e8007819b2 100644
--- a/io.c
+++ b/io.c
@@ -3029,14 +3029,8 @@ pipe_open(int argc, VALUE *argv, const char *mode)
/* parent */
if (pid == -1) {
int e = errno;
- if ((modef & FMODE_READABLE)) {
- close(arg.pair[0]);
- close(arg.pair[1]);
- }
- if ((modef & FMODE_WRITABLE)) {
- close(arg.pair[0]);
- close(arg.pair[1]);
- }
+ close(arg.pair[0]);
+ close(arg.pair[1]);
errno = e;
rb_sys_fail(cmd);
}