From cd948e46002a8e7fb8ff906e18a92da549669d81 Mon Sep 17 00:00:00 2001 From: matz Date: Fri, 12 Apr 2002 08:45:02 +0000 Subject: * struct.c (rb_struct_select): fix typo. * io.c (io_write): check error if written data is less than specified size to detect EPIPE. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2372 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- struct.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'struct.c') diff --git a/struct.c b/struct.c index 7e97e170f5..083bc83fe4 100644 --- a/struct.c +++ b/struct.c @@ -540,7 +540,7 @@ rb_struct_select(argc, argv, s) rb_raise(rb_eArgError, "wrong number arguments(%d for 0)", argc); } for (i = 0; i < RSTRUCT(s)->len; i++) { - if (RTEST(rb_yield(RARRAY(s)->ptr[i]))) { + if (RTEST(rb_yield(RSTRUCT(s)->ptr[i]))) { rb_ary_push(result, RSTRUCT(s)->ptr[i]); } } -- cgit v1.2.3