summaryrefslogtreecommitdiff
path: root/array.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-05-15 08:49:23 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-05-15 08:49:23 +0000
commitbe256c6f5a0180ac3eef05075f8b3977d29dfcb7 (patch)
tree80b8fb91a7a668c70f42757bfc8d563bf63242ba /array.c
parent91fdbecbdaa25387e19050dbf9234d245c8246b8 (diff)
* array.c (rb_ary_and): should not push frozen key string.
* array.c (rb_ary_or): ditto. * eval.c (rb_thread_schedule): should save context before raising deadlock, saved context for current thread might be obsolete. * time.c (make_time_t): non DST timezone shift supported (hopefully). * signal.c: SIGINFO added. * eval.c (rb_ensure): should not SEGV when prot_tag is NULL. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_6@1395 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'array.c')
-rw-r--r--array.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/array.c b/array.c
index c0c55fa07d..e885ca5b07 100644
--- a/array.c
+++ b/array.c
@@ -1468,7 +1468,7 @@ rb_ary_and(ary1, ary2)
for (i=0; i<RARRAY(ary1)->len; i++) {
VALUE v = RARRAY(ary1)->ptr[i];
if (st_delete(RHASH(hash)->tbl, &v, 0)) {
- rb_ary_push(ary3, v);
+ rb_ary_push(ary3, RARRAY(ary1)->ptr[i]);
}
}
@@ -1490,13 +1490,13 @@ rb_ary_or(ary1, ary2)
for (i=0; i<RARRAY(ary1)->len; i++) {
v = RARRAY(ary1)->ptr[i];
if (st_delete(RHASH(hash)->tbl, &v, 0)) {
- rb_ary_push(ary3, v);
+ rb_ary_push(ary3, RARRAY(ary1)->ptr[i]);
}
}
for (i=0; i<RARRAY(ary2)->len; i++) {
v = RARRAY(ary2)->ptr[i];
if (st_delete(RHASH(hash)->tbl, &v, 0)) {
- rb_ary_push(ary3, v);
+ rb_ary_push(ary3, RARRAY(ary1)->ptr[i]);
}
}