diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | lib/find.rb | 1 |
2 files changed, 7 insertions, 0 deletions
@@ -1,3 +1,9 @@ +Mon Oct 13 16:32:56 2014 Tanaka Akira <akr@fsij.org> + + * lib/find.rb (Find.find): Call to_path for arguments to obtain + strings. + [ruby-core:63713] [Bug #10035] Reported by Herwin. + Mon Oct 13 15:42:25 2014 SHIBATA Hiroshi <shibata.hiroshi@gmail.com> * common.mk: use relative load path for bundled_gems directory. diff --git a/lib/find.rb b/lib/find.rb index 46e2512b9e..55783a5695 100644 --- a/lib/find.rb +++ b/lib/find.rb @@ -40,6 +40,7 @@ module Find fs_encoding = Encoding.find("filesystem") paths.collect!{|d| raise Errno::ENOENT unless File.exist?(d); d.dup}.each do |path| + path = path.to_path if path.respond_to? :to_path enc = path.encoding == Encoding::US_ASCII ? fs_encoding : path.encoding ps = [path] while file = ps.shift |