[前][次][番号順一覧][スレッド一覧]

ruby-changes:33824

From: nagachika <ko1@a...>
Date: Sat, 10 May 2014 23:25:32 +0900 (JST)
Subject: [ruby-changes:33824] nagachika:r45905 (ruby_2_1): merge revision(s) r45891, r45893, r45895:

nagachika	2014-05-10 23:25:23 +0900 (Sat, 10 May 2014)

  New Revision: 45905

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=45905

  Log:
    merge revision(s) r45891,r45893,r45895:
    
    test_beginendblock.rb, test_signal.rb: run with default handler
    
    * test/ruby/test_beginendblock.rb (test_propagate_signaled): run
      with default handler.
    
    * test/ruby/test_signal.rb (test_hup_me): ditto.

  Modified directories:
    branches/ruby_2_1/
  Modified files:
    branches/ruby_2_1/test/ruby/test_beginendblock.rb
    branches/ruby_2_1/test/ruby/test_signal.rb
    branches/ruby_2_1/test/ruby/test_thread.rb
    branches/ruby_2_1/version.h
Index: ruby_2_1/version.h
===================================================================
--- ruby_2_1/version.h	(revision 45904)
+++ ruby_2_1/version.h	(revision 45905)
@@ -1,10 +1,10 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_1/version.h#L1
 #define RUBY_VERSION "2.1.2"
-#define RUBY_RELEASE_DATE "2014-05-08"
-#define RUBY_PATCHLEVEL 95
+#define RUBY_RELEASE_DATE "2014-05-10"
+#define RUBY_PATCHLEVEL 96
 
 #define RUBY_RELEASE_YEAR 2014
 #define RUBY_RELEASE_MONTH 5
-#define RUBY_RELEASE_DAY 8
+#define RUBY_RELEASE_DAY 10
 
 #include "ruby/version.h"
 
Index: ruby_2_1/test/ruby/test_beginendblock.rb
===================================================================
--- ruby_2_1/test/ruby/test_beginendblock.rb	(revision 45904)
+++ ruby_2_1/test/ruby/test_beginendblock.rb	(revision 45905)
@@ -112,6 +112,7 @@ EOW https://github.com/ruby/ruby/blob/trunk/ruby_2_1/test/ruby/test_beginendblock.rb#L112
     ruby = EnvUtil.rubybin
     out = IO.popen(
       [ruby,
+       '-e', 'trap(:INT, "DEFAULT")',
        '-e', 'STDERR.reopen(STDOUT)',
        '-e', 'at_exit{Process.kill(:INT, $$); sleep 5 }']) {|f|
       timeout(10) {
Index: ruby_2_1/test/ruby/test_signal.rb
===================================================================
--- ruby_2_1/test/ruby/test_signal.rb	(revision 45904)
+++ ruby_2_1/test/ruby/test_signal.rb	(revision 45905)
@@ -255,9 +255,12 @@ EOS https://github.com/ruby/ruby/blob/trunk/ruby_2_1/test/ruby/test_signal.rb#L255
     # that signal will be deliverd synchronously.
     # This ugly workaround was introduced to don't break
     # compatibility against silly example codes.
+    assert_separately([], <<-RUBY)
+    trap(:HUP, "DEFAULT")
     assert_raise(SignalException) {
       Process.kill('HUP', Process.pid)
     }
+    RUBY
     bug8137 = '[ruby-dev:47182] [Bug #8137]'
     assert_nothing_raised(bug8137) {
       Timeout.timeout(1) {
Index: ruby_2_1/test/ruby/test_thread.rb
===================================================================
--- ruby_2_1/test/ruby/test_thread.rb	(revision 45904)
+++ ruby_2_1/test/ruby/test_thread.rb	(revision 45905)
@@ -726,7 +726,7 @@ _eom https://github.com/ruby/ruby/blob/trunk/ruby_2_1/test/ruby/test_thread.rb#L726
     bug5757 = '[ruby-dev:44985]'
     t0 = Time.now.to_f
     pid = nil
-    cmd = 'r,=IO.pipe; Thread.start {Thread.pass until Thread.main.stop?; puts; STDOUT.flush}; r.read'
+    cmd = 'Signal.trap(:INT, "DEFAULT"); r,=IO.pipe; Thread.start {Thread.pass until Thread.main.stop?; puts; STDOUT.flush}; r.read'
     opt = {}
     opt[:new_pgroup] = true if /mswin|mingw/ =~ RUBY_PLATFORM
     s, _err = EnvUtil.invoke_ruby(['-e', cmd], "", true, true, opt) do |in_p, out_p, err_p, cpid|
@@ -746,6 +746,7 @@ _eom https://github.com/ruby/ruby/blob/trunk/ruby_2_1/test/ruby/test_thread.rb#L746
 
   def test_thread_join_in_trap
     assert_separately [], <<-'EOS'
+    Signal.trap(:INT, "DEFAULT")
     t0 = Thread.current
     assert_nothing_raised{
       t = Thread.new {Thread.pass until t0.stop?; Process.kill(:INT, $$)}
@@ -761,6 +762,7 @@ _eom https://github.com/ruby/ruby/blob/trunk/ruby_2_1/test/ruby/test_thread.rb#L762
 
   def test_thread_value_in_trap
     assert_separately [], <<-'EOS'
+    Signal.trap(:INT, "DEFAULT")
     t0 = Thread.current
     t = Thread.new {Thread.pass until t0.stop?; Process.kill(:INT, $$); :normal_end}
 

Property changes on: ruby_2_1
___________________________________________________________________
Modified: svn:mergeinfo
   Merged /trunk:r45891,45893,45895


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]