Project

General

Profile

Bug #7398

Modify TestSSL#test_read_and_write to handle partial sysreads

Added by Zachary Scott over 3 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Normal
ruby -v:
2.0.0
Backport:
[ruby-core:49563]

Description

=begin
from github: https://github.com/ruby/ruby/pull/204

((*SSLSocket#sysread can return fewer bytes than you request. This test does client reads and writes and server reads and writes concurrently, which means on a parallel-threaded implementation like JRuby there's a chance the client side will see partial data come from sysread.

My change here ensures that the sysread has read everything written before doing comparisons, allowing for partial sysread results.*))
=end

openssl_test_read_and_write.patch Magnifier (2.29 KB) Zachary Scott, 11/19/2012 01:03 PM

Associated revisions

Revision 46164
Added by Hiroshi SHIBATA about 2 years ago

  • test/openssl/test_pair.rb: Modify TestSSL#test_read_and_write to handle partial sysreads. [Bug #7398]
  • test/openssl/test_ssl.rb: ditto.

Revision 46164
Added by Hiroshi SHIBATA about 2 years ago

  • test/openssl/test_pair.rb: Modify TestSSL#test_read_and_write to handle partial sysreads. [Bug #7398]
  • test/openssl/test_ssl.rb: ditto.

Revision 46164
Added by Hiroshi SHIBATA about 2 years ago

  • test/openssl/test_pair.rb: Modify TestSSL#test_read_and_write to handle partial sysreads. [Bug #7398]
  • test/openssl/test_ssl.rb: ditto.

History

#1 [ruby-core:49564] Updated by Zachary Scott over 3 years ago

=begin
Description update:

((SSLSocket#sysread can return fewer bytes than you request. This test does client reads and writes and server reads and writes concurrently, which means on a parallel-threaded implementation like JRuby there's a chance the client side will see partial data come from sysread.))

((My change here ensures that the sysread has read everything written before doing comparisons, allowing for partial sysread results.))
=end

#2 [ruby-core:51042] Updated by Usaku NAKAMURA over 3 years ago

  • Status changed from Open to Assigned

#3 [ruby-core:52475] Updated by Yusuke Endoh over 3 years ago

  • Target version changed from 2.0.0 to next minor

Just an issue of test.

--
Yusuke Endoh mame@tsg.ne.jp

#4 [ruby-core:62793] Updated by Hiroshi SHIBATA about 2 years ago

  • Status changed from Assigned to Closed
  • % Done changed from 0 to 100

Applied in changeset r46164.


  • test/openssl/test_pair.rb: Modify TestSSL#test_read_and_write to handle partial sysreads. [Bug #7398]
  • test/openssl/test_ssl.rb: ditto.

Also available in: Atom PDF