summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-11-28 07:13:34 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-11-28 07:13:34 +0000
commit3412d1016a4a166d7e7bf32e56bcde5cc25f19ae (patch)
tree8144d7220563d805dcc2398c05e9091f22121cea
parent32ecaac7b18cc5f0b0cee90801819b8e53930870 (diff)
merge revision(s) 47079: [Backport #10530]
* lib/net/http.rb (Net::HTTP.proxy_uri): use initializer instead of parser to handle IPv6 address. [Bug #9129] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@48632 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--lib/net/http.rb4
-rw-r--r--version.h2
3 files changed, 9 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 9093b02937..3c90a4e5e5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Fri Nov 28 16:12:22 2014 NARUSE, Yui <naruse@ruby-lang.org>
+
+ * lib/net/http.rb (Net::HTTP.proxy_uri): use initializer instead
+ of parser to handle IPv6 address. [Bug #9129]
+
Fri Nov 28 16:05:09 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
* io.c (copy_stream_body): should write in binary mode. based on a
diff --git a/lib/net/http.rb b/lib/net/http.rb
index 973998fdc3..a63be7f9a0 100644
--- a/lib/net/http.rb
+++ b/lib/net/http.rb
@@ -1024,7 +1024,9 @@ module Net #:nodoc:
# The proxy URI determined from the environment for this connection.
def proxy_uri # :nodoc:
- @proxy_uri ||= URI("http://#{address}:#{port}").find_proxy
+ @proxy_uri ||= URI::HTTP.new(
+ "http".freeze, nil, address, port, nil, nil, nil, nil, nil
+ ).find_proxy
end
# The address of the proxy server, if one is configured.
diff --git a/version.h b/version.h
index a89be87f6d..48a0af5d4a 100644
--- a/version.h
+++ b/version.h
@@ -1,6 +1,6 @@
#define RUBY_VERSION "2.0.0"
#define RUBY_RELEASE_DATE "2014-11-28"
-#define RUBY_PATCHLEVEL 601
+#define RUBY_PATCHLEVEL 602
#define RUBY_RELEASE_YEAR 2014
#define RUBY_RELEASE_MONTH 11