Skip to content

Commit 0797b0d

Browse files
committed
ssl: eliminate SSLContext::INIT_VARS (not used on JRuby anyways)
ruby/openssl@98a3106 (almost)
1 parent 08fecc7 commit 0797b0d

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

lib/jopenssl23/openssl/ssl.rb

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -108,10 +108,8 @@ class SSLContext
108108
#
109109
# You can get a list of valid methods with OpenSSL::SSL::SSLContext::METHODS
110110
def initialize(version = nil)
111-
INIT_VARS.each { |v| instance_variable_set v, nil }
112-
self.options = self.options | OpenSSL::SSL::OP_ALL
113-
return unless version
114-
self.ssl_version = version
111+
self.options |= OpenSSL::SSL::OP_ALL
112+
self.ssl_version = version if version
115113
end unless defined? JRUBY_VERSION # JRuby: handled in "native" Java
116114

117115
##

0 commit comments

Comments
 (0)