aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew
diff options
context:
space:
mode:
authorJack Nagel2013-02-11 17:14:25 -0600
committerJack Nagel2013-02-11 17:14:26 -0600
commite22af691494137a6a362abf38f37bcee062b25e7 (patch)
treeaad1d61a7318e55edd3b83f7dc936ec1626942d5 /Library/Homebrew
parentc16ee6f30004405b7082db4088ba38400853a89f (diff)
downloadbrew-e22af691494137a6a362abf38f37bcee062b25e7.tar.bz2
Catch JSON decoding errors in Apache download strategy
c.f. Homebrew/homebrew#17772.
Diffstat (limited to 'Library/Homebrew')
-rw-r--r--Library/Homebrew/download_strategy.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/download_strategy.rb b/Library/Homebrew/download_strategy.rb
index 07e700cdc..7d6f97262 100644
--- a/Library/Homebrew/download_strategy.rb
+++ b/Library/Homebrew/download_strategy.rb
@@ -158,7 +158,7 @@ class CurlApacheMirrorDownloadStrategy < CurlDownloadStrategy
ohai "Best Mirror #{url}"
curl url, '-C', downloaded_size, '-o', @temporary_path
- rescue IndexError
+ rescue IndexError, MultiJson::DecodeError
raise "Couldn't determine mirror. Try again later."
end
end