From a02b33742cc3c6fb134737636f7df951b14e9338 Mon Sep 17 00:00:00 2001 From: nobu Date: Sun, 21 Jun 2009 01:47:25 +0000 Subject: * lib/fileutils.rb (FileUtils::Entry_#copy_file): open with default umask. [ruby-core:23952] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23774 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/fileutils.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/fileutils.rb b/lib/fileutils.rb index 6124f29894..2a6b248585 100644 --- a/lib/fileutils.rb +++ b/lib/fileutils.rb @@ -1261,7 +1261,9 @@ module FileUtils end def copy_file(dest) - IO.copy_stream(path(), dest) + File.open(dest, 'wb') do |f| + IO.copy_stream(path(), f) + end end def copy_metadata(path) -- cgit v1.2.3