aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd/fetch.rb
diff options
context:
space:
mode:
authorJack Nagel2014-08-22 22:55:10 -0500
committerJack Nagel2014-08-22 22:55:10 -0500
commitfd4f985cb6a915baf2dabb1d6b9b07b1d7d138a1 (patch)
treea09b6b69f14a717c81b7a97b903a4c636a4abfd2 /Library/Homebrew/cmd/fetch.rb
parent262a503b6f0080f413a4dca72384e00b6a83f602 (diff)
downloadbrew-fd4f985cb6a915baf2dabb1d6b9b07b1d7d138a1.tar.bz2
Rescue only DownloadError
Diffstat (limited to 'Library/Homebrew/cmd/fetch.rb')
-rw-r--r--Library/Homebrew/cmd/fetch.rb5
1 files changed, 2 insertions, 3 deletions
diff --git a/Library/Homebrew/cmd/fetch.rb b/Library/Homebrew/cmd/fetch.rb
index 0c3d39b4b..cb86545ae 100644
--- a/Library/Homebrew/cmd/fetch.rb
+++ b/Library/Homebrew/cmd/fetch.rb
@@ -79,13 +79,12 @@ module Homebrew
f.clear_cache if ARGV.force?
already_fetched = f.cached_download.exist?
- download = nil
begin
download = f.fetch
- rescue => e
+ rescue DownloadError
retry if retry_fetch? f
- raise e
+ raise
end
return unless download.file?