ruby-changes:30832
From: nagachika <ko1@a...>
Date: Thu, 12 Sep 2013 00:27:21 +0900 (JST)
Subject: [ruby-changes:30832] nagachika:r42911 (ruby_2_0_0): merge revision(s) 42867: [Backport #8873]
nagachika 2013-09-12 00:27:13 +0900 (Thu, 12 Sep 2013) New Revision: 42911 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=42911 Log: merge revision(s) 42867: [Backport #8873] * variable.c (classname): the name of class that has non class id should not be nil. This bug was introduced in r36577. * test/thread/test_cv.rb: test for change. Modified directories: branches/ruby_2_0_0/ Modified files: branches/ruby_2_0_0/ChangeLog branches/ruby_2_0_0/test/thread/test_cv.rb branches/ruby_2_0_0/variable.c branches/ruby_2_0_0/version.h Index: ruby_2_0_0/ChangeLog =================================================================== --- ruby_2_0_0/ChangeLog (revision 42910) +++ ruby_2_0_0/ChangeLog (revision 42911) @@ -1,3 +1,11 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_0_0/ChangeLog#L1 +Thu Sep 12 00:22:22 2013 Kazuki Tsujimoto <kazuki@c...> + + * variable.c (classname): the name of class that has + non class id should not be nil. This bug was introduced + in r36577. + + * test/thread/test_cv.rb: test for change. + Thu Aug 29 21:51:33 2013 Eric Hodel <drbrain@s...> * ext/zlib/zlib.c (zstream_run): Fix handling of deflate streams that Index: ruby_2_0_0/variable.c =================================================================== --- ruby_2_0_0/variable.c (revision 42910) +++ ruby_2_0_0/variable.c (revision 42911) @@ -175,9 +175,14 @@ classname(VALUE klass, int *permanent) https://github.com/ruby/ruby/blob/trunk/ruby_2_0_0/variable.c#L175 path = find_class_path(klass, (ID)0); } if (NIL_P(path)) { - if (!cid || !st_lookup(RCLASS_IV_TBL(klass), (st_data_t)tmp_classpath, &n)) { + if (!cid) { return Qnil; } + if (!st_lookup(RCLASS_IV_TBL(klass), (st_data_t)tmp_classpath, &n)) { + path = rb_str_dup(rb_id2str(cid)); + OBJ_FREEZE(path); + return path; + } *permanent = 0; path = (VALUE)n; return path; Index: ruby_2_0_0/version.h =================================================================== --- ruby_2_0_0/version.h (revision 42910) +++ ruby_2_0_0/version.h (revision 42911) @@ -1,10 +1,10 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_0_0/version.h#L1 #define RUBY_VERSION "2.0.0" -#define RUBY_RELEASE_DATE "2013-08-29" -#define RUBY_PATCHLEVEL 299 +#define RUBY_RELEASE_DATE "2013-09-12" +#define RUBY_PATCHLEVEL 300 #define RUBY_RELEASE_YEAR 2013 -#define RUBY_RELEASE_MONTH 8 -#define RUBY_RELEASE_DAY 29 +#define RUBY_RELEASE_MONTH 9 +#define RUBY_RELEASE_DAY 12 #include "ruby/version.h" Index: ruby_2_0_0/test/thread/test_cv.rb =================================================================== --- ruby_2_0_0/test/thread/test_cv.rb (revision 42910) +++ ruby_2_0_0/test/thread/test_cv.rb (revision 42911) @@ -82,20 +82,23 @@ class TestConditionVariable < Test::Unit https://github.com/ruby/ruby/blob/trunk/ruby_2_0_0/test/thread/test_cv.rb#L82 end def test_condvar_wait_deadlock - assert_in_out_err([], <<-INPUT, ["No live threads left. Deadlock?"], []) + assert_in_out_err([], <<-INPUT, ["fatal", "No live threads left. Deadlock?"], []) require "thread" mutex = Mutex.new cv = ConditionVariable.new + klass = nil mesg = nil begin mutex.lock cv.wait mutex mutex.unlock rescue Exception => e + klass = e.class mesg = e.message end + puts klass print mesg INPUT end Property changes on: ruby_2_0_0 ___________________________________________________________________ Modified: svn:mergeinfo Merged /trunk:r42867 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/