ruby-changes:30711
From: usa <ko1@a...>
Date: Tue, 3 Sep 2013 10:08:32 +0900 (JST)
Subject: [ruby-changes:30711] usa:r42790 (trunk): * test/openssl/test_pair.rb
usa 2013-09-03 10:08:09 +0900 (Tue, 03 Sep 2013) New Revision: 42790 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=42790 Log: * test/openssl/test_pair.rb (OpenSSL::TestPair#test_write_nonblock_no_exceptions): on some CIs such as Debian 6.0, Ubuntu 10.04, CentOS and vc10-x64 (maybe depend on OpenSSL version), writing to SSLSocket after SSL_ERROR_WANT_WRITE causes SSL_ERROR_SSL "bad write retry". Modified files: trunk/ChangeLog trunk/test/openssl/test_pair.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 42789) +++ ChangeLog (revision 42790) @@ -1,3 +1,11 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Tue Sep 3 10:03:42 2013 NAKAMURA Usaku <usa@r...> + + * test/openssl/test_pair.rb + (OpenSSL::TestPair#test_write_nonblock_no_exceptions): on some CIs + such as Debian 6.0, Ubuntu 10.04, CentOS and vc10-x64 (maybe depend + on OpenSSL version), writing to SSLSocket after SSL_ERROR_WANT_WRITE + causes SSL_ERROR_SSL "bad write retry". + Tue Sep 3 08:20:46 2013 NARUSE, Yui <naruse@r...> * enc/trans/utf8_mac-tbl.rb: update conversion table to recent OS X. Index: test/openssl/test_pair.rb =================================================================== --- test/openssl/test_pair.rb (revision 42789) +++ test/openssl/test_pair.rb (revision 42790) @@ -206,12 +206,18 @@ class OpenSSL::TestPair < Test::Unit::Te https://github.com/ruby/ruby/blob/trunk/test/openssl/test_pair.rb#L206 def test_write_nonblock_no_exceptions ssl_pair {|s1, s2| n = 0 - n += write_nonblock_no_ex s1, "a" * 100000 - n += write_nonblock_no_ex s1, "b" * 100000 - n += write_nonblock_no_ex s1, "c" * 100000 - n += write_nonblock_no_ex s1, "d" * 100000 - n += write_nonblock_no_ex s1, "e" * 100000 - n += write_nonblock_no_ex s1, "f" * 100000 + begin + n += write_nonblock_no_ex s1, "a" * 100000 + n += write_nonblock_no_ex s1, "b" * 100000 + n += write_nonblock_no_ex s1, "c" * 100000 + n += write_nonblock_no_ex s1, "d" * 100000 + n += write_nonblock_no_ex s1, "e" * 100000 + n += write_nonblock_no_ex s1, "f" * 100000 + rescue OpenSSL::SSL::SSLError => e + # on some platforms (maybe depend on OpenSSL version), writing to + # SSLSocket after SSL_ERROR_WANT_WRITE causes this error. + raise e if n == 0 + end s1.close assert_equal(n, s2.read.length) } -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/