зеркало из https://github.com/github/ruby.git
* lib/find.rb (Find.find): removed already unnecessary code.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26085 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
b3ea5a1789
Коммит
cc744ef9b8
|
@ -1,3 +1,7 @@
|
||||||
|
Mon Dec 14 09:20:54 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* lib/find.rb (Find.find): removed already unnecessary code.
|
||||||
|
|
||||||
Sun Dec 13 23:48:25 2009 Tanaka Akira <akr@fsij.org>
|
Sun Dec 13 23:48:25 2009 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
* lib/find.rb (Find.find): sort directory entries. [ruby-dev:39847]
|
* lib/find.rb (Find.find): sort directory entries. [ruby-dev:39847]
|
||||||
|
|
|
@ -50,13 +50,7 @@ module Find
|
||||||
fs.sort!
|
fs.sort!
|
||||||
fs.reverse_each {|f|
|
fs.reverse_each {|f|
|
||||||
next if f == "." or f == ".."
|
next if f == "." or f == ".."
|
||||||
if File::ALT_SEPARATOR and file =~ /^(?:[\/\\]|[A-Za-z]:[\/\\]?)$/ then
|
f = File.join(file, f)
|
||||||
f = file + f
|
|
||||||
elsif file == "/" then
|
|
||||||
f = "/" + f
|
|
||||||
else
|
|
||||||
f = File.join(file, f)
|
|
||||||
end
|
|
||||||
paths.unshift f.untaint
|
paths.unshift f.untaint
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
Загрузка…
Ссылка в новой задаче