From 7ab214d982d208b6578f599b2477664e67fc39f4 Mon Sep 17 00:00:00 2001 From: matz Date: Tue, 31 Oct 2006 07:28:37 +0000 Subject: * array.c (ary_shared_first): should address offset after ary_shared_array(). [ruby-core:09358] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11247 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- array.c | 1 + 1 file changed, 1 insertion(+) (limited to 'array.c') diff --git a/array.c b/array.c index bfaf85e85f..65d4d25c09 100644 --- a/array.c +++ b/array.c @@ -517,6 +517,7 @@ ary_shared_first(int argc, VALUE *argv, VALUE ary, int last) } else { result = ary_shared_array(rb_cArray, ary); + RARRAY(result)->as.heap.ptr += offset; RARRAY(result)->as.heap.len = n; } return result; -- cgit v1.2.3