* eval.c (thgroup_add): no warning for terminated threads.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
matz 2003-07-24 05:18:47 +00:00
parent 169300a4f8
commit e02b469de1
8 changed files with 88 additions and 26 deletions

View file

@ -2557,7 +2557,11 @@ rb_str_split_m(argc, argv, str)
if (rb_scan_args(argc, argv, "02", &spat, &limit) == 2) {
lim = NUM2INT(limit);
if (lim <= 0) limit = Qnil;
else if (lim == 1) return rb_ary_new3(1, str);
else if (lim == 1) {
if (RSTRING(str)->len == 0)
return rb_ary_new2(0);
return rb_ary_new3(1, str);
}
i = 1;
}