summaryrefslogtreecommitdiff
path: root/array.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-11-03 18:28:34 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-11-03 18:28:34 +0000
commita2a9858b98e2726a28ff96fba4e3501d2268955b (patch)
tree3a9bc56d08801977a1ff198f504fd6d05cbfd4ec /array.c
parent55adf41182806bb9b7c5e24d457119649b119721 (diff)
* array.c (rb_ary_join): do not repeat self in a recursive array.
[ruby-dev:37019] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@20103 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'array.c')
-rw-r--r--array.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/array.c b/array.c
index 5e2ed4db92..d063b06bd6 100644
--- a/array.c
+++ b/array.c
@@ -1405,7 +1405,7 @@ rb_ary_join(ary, sep)
case T_STRING:
break;
case T_ARRAY:
- if (rb_inspecting_p(tmp)) {
+ if (tmp == ary || rb_inspecting_p(tmp)) {
tmp = rb_str_new2("[...]");
}
else {