From fb59e79689b15d71e6090d0f6f1f39f4d69800b1 Mon Sep 17 00:00:00 2001 From: Markus Reiter Date: Sat, 1 Jul 2017 17:57:39 +0200 Subject: Simplify SubversionDownloadStrategy. --- Library/Homebrew/cask/lib/hbc/container/executable.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Library/Homebrew/cask/lib/hbc/container/executable.rb') diff --git a/Library/Homebrew/cask/lib/hbc/container/executable.rb b/Library/Homebrew/cask/lib/hbc/container/executable.rb index 848f6d4be..af3b36fd1 100644 --- a/Library/Homebrew/cask/lib/hbc/container/executable.rb +++ b/Library/Homebrew/cask/lib/hbc/container/executable.rb @@ -8,7 +8,7 @@ module Hbc return true if criteria.magic_number(/^#!\s*\S+/) begin - MachO.open(criteria.path).header.executable? + criteria.path.file? && MachO.open(criteria.path).header.executable? rescue MachO::MagicError false end -- cgit v1.2.3