diff options
author | David RodrÃguez <[email protected]> | 2022-08-01 20:35:37 +0200 |
---|---|---|
committer | git <[email protected]> | 2022-08-22 10:12:25 +0900 |
commit | 70f69f85395f5735429cd45136d7de2742f08b72 (patch) | |
tree | 3c0746f40f68f88b558dee9c25f2a327236e9873 /lib/fileutils.rb | |
parent | 9f3140a42e3542dce565a27135dceeb135a4e691 (diff) |
[ruby/fileutils] Fix mkdir_p hanging on Windows when trying to create a file on a offline drive
https://github.com/ruby/fileutils/commit/9cc6a082d7
Diffstat (limited to 'lib/fileutils.rb')
-rw-r--r-- | lib/fileutils.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/fileutils.rb b/lib/fileutils.rb index 7eb66dda0c..8ae5266864 100644 --- a/lib/fileutils.rb +++ b/lib/fileutils.rb @@ -374,7 +374,7 @@ module FileUtils path = remove_trailing_slash(item) stack = [] - until File.directory?(path) + until File.directory?(path) || File.dirname(path) == path stack.push path path = File.dirname(path) end |