summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorshyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-19 10:46:48 +0000
committershyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-19 10:46:48 +0000
commite23e534ae5d38b552e0c8f63e79c0e341c7439ce (patch)
treeff09d6d14e90deb759e58f6f5f16b3e465911ad0
parent3dea38333c0aec312f949d11e407ead6b81f8e62 (diff)
* lib/fileutils.rb (FileUtils::cp_r): dup needed here; options are
destroyed otherwise. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@27400 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--lib/fileutils.rb1
2 files changed, 6 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 346b9be20a..1fad4ef658 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Mon Apr 19 19:42:08 2010 URABE Shyouhei <[email protected]>
+
+ * lib/fileutils.rb (FileUtils::cp_r): dup needed here; options are
+ destroyed otherwise.
+
Mon Apr 19 19:13:12 2010 Nobuyoshi Nakada <[email protected]>
* eval.c (search_required): expand home relative path first.
diff --git a/lib/fileutils.rb b/lib/fileutils.rb
index 064baa6e25..d3a623f808 100644
--- a/lib/fileutils.rb
+++ b/lib/fileutils.rb
@@ -418,6 +418,7 @@ module FileUtils
fu_check_options options, OPT_TABLE['cp_r']
fu_output_message "cp -r#{options[:preserve] ? 'p' : ''}#{options[:remove_destination] ? ' --remove-destination' : ''} #{[src,dest].flatten.join ' '}" if options[:verbose]
return if options[:noop]
+ options = options.dup
options[:dereference_root] = true unless options.key?(:dereference_root)
fu_each_src_dest(src, dest) do |s, d|
copy_entry s, d, options[:preserve], options[:dereference_root], options[:remove_destination]