summaryrefslogtreecommitdiff
path: root/ext/openssl/lib
diff options
context:
space:
mode:
authorgotoyuzo <gotoyuzo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-10-29 17:27:59 +0000
committergotoyuzo <gotoyuzo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-10-29 17:27:59 +0000
commit2e0b6e28ada7713aab10343c2850f32dec4652ac (patch)
tree81a2bc1f0747c75b48345a1df1ba3770fbe16b91 /ext/openssl/lib
parent2d6b30ee5704b349d2e8b4778427fc022e7cbb5a (diff)
* ext/openssl/lib/openssl/buffering.rb (Buffering#initialize):
add new method to inherit @sync from @io.sync. * ext/openssl/lib/net/protocols.rb (SSLIO#ssl_connect): no need to set sync flag explicitly. * ext/openssl/ossl_ssl.c (ossl_sslctx_initialize): call super. * ext/openssl/ossl_ssl.c (ossl_sslctx_setup): set extra chain certificates in @extra_chain_cert. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4859 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/openssl/lib')
-rw-r--r--ext/openssl/lib/net/protocols.rb1
-rw-r--r--ext/openssl/lib/openssl/buffering.rb4
-rw-r--r--ext/openssl/lib/openssl/ssl.rb1
3 files changed, 4 insertions, 2 deletions
diff --git a/ext/openssl/lib/net/protocols.rb b/ext/openssl/lib/net/protocols.rb
index 36c5077..073d4f3 100644
--- a/ext/openssl/lib/net/protocols.rb
+++ b/ext/openssl/lib/net/protocols.rb
@@ -45,7 +45,6 @@ module Net
@ssl_context.verify_mode = OpenSSL::SSL::VERIFY_NONE
end
@socket = OpenSSL::SSL::SSLSocket.new(@socket, @ssl_context)
- @socket.sync = true
@socket.sync_close = true
@socket.connect
end
diff --git a/ext/openssl/lib/openssl/buffering.rb b/ext/openssl/lib/openssl/buffering.rb
index 031af4b..fdbd71b 100644
--- a/ext/openssl/lib/openssl/buffering.rb
+++ b/ext/openssl/lib/openssl/buffering.rb
@@ -19,6 +19,10 @@ module Buffering
attr_accessor :sync
BLOCK_SIZE = 1024*16
+ def initialize(*args)
+ @sync = @io.sync
+ end
+
#
# for reading.
#
diff --git a/ext/openssl/lib/openssl/ssl.rb b/ext/openssl/lib/openssl/ssl.rb
index 38bf4b7..811a935 100644
--- a/ext/openssl/lib/openssl/ssl.rb
+++ b/ext/openssl/lib/openssl/ssl.rb
@@ -71,7 +71,6 @@ module OpenSSL
sock = @svr.accept
begin
ssl = OpenSSL::SSL::SSLSocket.new(sock, @ctx)
- ssl.sync = true
ssl.sync_close = true
ssl.accept if @start_immediately
ssl