Skip to content
Snippets Groups Projects
Commit 822b05c9 authored by Mike McQuaid's avatar Mike McQuaid
Browse files

cmd/pull: fix HTTP header usage.

parent 8a217dd4
No related branches found
No related tags found
No related merge requests found
......@@ -503,12 +503,12 @@ module Homebrew
url = URI(bottle_info.url)
puts "Verifying bottle: #{File.basename(url.path)}"
http = Net::HTTP.new(url.host, url.port)
http.initialize_http_header "User-Agent" => HOMEBREW_USER_AGENT_RUBY
http.use_ssl = true
retry_count = 0
http.start do
while true do
req = Net::HTTP::Head.new bottle_info.url
req.initialize_http_header "User-Agent" => HOMEBREW_USER_AGENT_RUBY
res = http.request req
if res.is_a?(Net::HTTPSuccess)
break
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment