diff options
| author | Tijs Zwinkels - TinkerTank | 2013-08-05 07:04:15 +0100 |
|---|---|---|
| committer | Adam Vandenberg | 2013-08-05 09:12:32 -0700 |
| commit | 008476940f0fc4191657d3df8f80ae2866a87e81 (patch) | |
| tree | 057299989a00e259ae8222b8e03db9450f0eb523 /Library | |
| parent | db8e8c780eede6c81e9802aa40ba5e882358fa84 (diff) | |
| download | brew-008476940f0fc4191657d3df8f80ae2866a87e81.tar.bz2 | |
Add support for the :ssl3 download-strategy.
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/download_strategy.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Library/Homebrew/download_strategy.rb b/Library/Homebrew/download_strategy.rb index 2d2fe1c28..17ee4143f 100644 --- a/Library/Homebrew/download_strategy.rb +++ b/Library/Homebrew/download_strategy.rb @@ -199,6 +199,13 @@ class CurlPostDownloadStrategy < CurlDownloadStrategy end end +# Download from an SSL3-only host. +class CurlSSL3DownloadStrategy < CurlDownloadStrategy + def _fetch + curl @url, '-3', '-C', downloaded_size, '-o', @temporary_path + end +end + # Use this strategy to download but not unzip a file. # Useful for installing jars. class NoUnzipCurlDownloadStrategy < CurlDownloadStrategy @@ -745,6 +752,7 @@ class DownloadStrategyDetector when :nounzip then NoUnzipCurlDownloadStrategy when :post then CurlPostDownloadStrategy when :svn then SubversionDownloadStrategy + when :ssl3 then CurlSSL3DownloadStrategy else raise "Unknown download strategy #{strategy} was requested." end |
