aboutsummaryrefslogtreecommitdiffstats
path: root/lib/net/http.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/net/http.rb')
-rw-r--r--lib/net/http.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/net/http.rb b/lib/net/http.rb
index f77df5efa3..f6499f2a59 100644
--- a/lib/net/http.rb
+++ b/lib/net/http.rb
@@ -912,8 +912,7 @@ module Net #:nodoc:
buf = "CONNECT #{@address}:#{@port} HTTP/#{HTTPVersion}\r\n"
buf << "Host: #{@address}:#{@port}\r\n"
if proxy_user
- credential = ["#{proxy_user}:#{proxy_pass}"].pack('m')
- credential.delete!("\r\n")
+ credential = ["#{proxy_user}:#{proxy_pass}"].pack('m0')
buf << "Proxy-Authorization: Basic #{credential}\r\n"
end
buf << "\r\n"