aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/extend
diff options
context:
space:
mode:
authorilovezfs2016-02-19 20:21:55 -0800
committerMike McQuaid2016-02-21 17:34:19 +0000
commit2517d396aa66e6a89ff84ce7573f8fa2397619d4 (patch)
tree7a55d760e613272d37cd0edd6da08e6cd254470a /Library/Homebrew/extend
parente6501c3768b9f5506374575740efcd47e8d09425 (diff)
downloadbrew-2517d396aa66e6a89ff84ce7573f8fa2397619d4.tar.bz2
FileUtils::mktemp fix for OS X 10.6.7 and earlier
FileUtils::fu_get_gid only started doing the conversion of the group to_s automatically from OS X 10.6.8 (ruby-1.8.7-p358) forward. OS X 10.6.7 (ruby-1.8.7-p174) would fail in brew's FileUtils::mktemp with the error "Error: can't convert Fixnum into String." Fixes Homebrew/homebrew#49045 Fixes Homebrew/homebrew#49348 Closes Homebrew/homebrew#49369. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library/Homebrew/extend')
-rw-r--r--Library/Homebrew/extend/fileutils.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/Library/Homebrew/extend/fileutils.rb b/Library/Homebrew/extend/fileutils.rb
index 9717c69f2..b3e1da87f 100644
--- a/Library/Homebrew/extend/fileutils.rb
+++ b/Library/Homebrew/extend/fileutils.rb
@@ -22,6 +22,8 @@ module FileUtils
else
Process.gid
end
+ # Make OS X 10.6.7 (ruby-1.8.7-p174) and earlier happy.
+ group_id = group_id.to_s
begin
chown(nil, group_id, tmp)
rescue Errno::EPERM