lib/openssl/ssl.rb in rubysl-openssl-2.8.0 vs lib/openssl/ssl.rb in rubysl-openssl-2.9
- old
+ new
@@ -249,11 +249,11 @@
class SSLSocket
include Buffering
include SocketForwarder
if ExtConfig::OPENSSL_NO_SOCK
- def initialize(io, ctx = nil); raise NotImplmentedError; end
+ def initialize(io, ctx = nil); raise NotImplementedError; end
else
if ExtConfig::HAVE_TLSEXT_HOST_NAME
attr_accessor :hostname
end
@@ -288,10 +288,13 @@
end
# call-seq:
# ssl.sysclose => nil
#
- # Shuts down the SSL connection and prepares it for another connection.
+ # Sends "close notify" to the peer and tries to shut down the SSL
+ # connection gracefully.
+ #
+ # If sync_close is set to +true+, the underlying IO is also closed.
def sysclose
return if closed?
stop
io.close if sync_close
end