aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorMarkus Reiter2017-04-21 14:12:16 +0200
committerMarkus Reiter2017-04-21 14:12:16 +0200
commitcc634b2d50cc0e8c1e8a38196f4bcdad4e0a69b6 (patch)
tree3cff0f361401afc5fca11fcc2dabcc18ee43ed64 /Library
parent9e089a7d1299db498f121e17b5f68f0cc3c40953 (diff)
downloadbrew-cc634b2d50cc0e8c1e8a38196f4bcdad4e0a69b6.tar.bz2
Set timeout to 10 seconds instead of retrying.
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/cask/lib/hbc/system_command.rb10
1 files changed, 2 insertions, 8 deletions
diff --git a/Library/Homebrew/cask/lib/hbc/system_command.rb b/Library/Homebrew/cask/lib/hbc/system_command.rb
index 65e54b447..f1ec34025 100644
--- a/Library/Homebrew/cask/lib/hbc/system_command.rb
+++ b/Library/Homebrew/cask/lib/hbc/system_command.rb
@@ -91,16 +91,10 @@ module Hbc
end
def each_line_from(sources)
- tries = 3
-
loop do
- selected_sources = IO.select(sources, [], [], 1)
+ selected_sources = IO.select(sources, [], [], 10)
- if selected_sources.nil?
- next unless (tries -= 1).zero?
- odebug "IO#select failed, skipping line."
- break
- end
+ break if selected_sources.nil?
readable_sources = selected_sources[0].delete_if(&:eof?)