ruby-changes:21799
From: naruse <ko1@a...>
Date: Sat, 26 Nov 2011 20:07:03 +0900 (JST)
Subject: [ruby-changes:21799] naruse:r33848 (trunk): * lib/net/http.rb (Net::HTTP::SSL_ATTRIBUTES): refix 33701.
naruse 2011-11-26 20:06:53 +0900 (Sat, 26 Nov 2011) New Revision: 33848 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=33848 Log: * lib/net/http.rb (Net::HTTP::SSL_ATTRIBUTES): refix 33701. store instance variable symbol names. Modified files: trunk/ChangeLog trunk/lib/net/http.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 33847) +++ ChangeLog (revision 33848) @@ -1,3 +1,8 @@ +Sat Nov 26 20:01:18 2011 NARUSE, Yui <naruse@r...> + + * lib/net/http.rb (Net::HTTP::SSL_ATTRIBUTES): refix 33701. + store instance variable symbol names. + Sat Nov 26 15:40:25 2011 URABE Shyouhei <shyouhei@r...> * .travis.yml (script): should be ./configure Index: lib/net/http.rb =================================================================== --- lib/net/http.rb (revision 33847) +++ lib/net/http.rb (revision 33848) @@ -591,7 +591,7 @@ @sspi_enabled = false if defined?(SSL_ATTRIBUTES) SSL_ATTRIBUTES.each do |name| - instance_variable_set "@#{name}", nil + instance_variable_set name, nil end end end @@ -675,17 +675,17 @@ end SSL_ATTRIBUTES = [ - :ca_file, - :ca_path, - :cert, - :cert_store, - :ciphers, - :key, - :ssl_timeout, - :ssl_version, - :verify_callback, - :verify_depth, - :verify_mode, + :@ca_file, + :@ca_path, + :@cert, + :@cert_store, + :@ciphers, + :@key, + :@ssl_timeout, + :@ssl_version, + :@verify_callback, + :@verify_depth, + :@verify_mode, ] # Sets path of a CA certification file in PEM format. @@ -773,8 +773,7 @@ if use_ssl? ssl_parameters = Hash.new iv_list = instance_variables - SSL_ATTRIBUTES.each do |name| - ivname = "@#{name}".intern + SSL_ATTRIBUTES.each do |ivname| if iv_list.include?(ivname) and value = instance_variable_get(ivname) ssl_parameters[name] = value -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/