mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Fix assertion if FS root is not readable
(e.g. http://devnet.jetbrains.net/message/5457053)
This commit is contained in:
+2
-1
@@ -212,7 +212,8 @@ public abstract class LocalFileSystemBase extends LocalFileSystem {
|
||||
if (file.getParent() == null) {
|
||||
final File[] roots = File.listRoots();
|
||||
if (roots.length == 1 && roots[0].getName().isEmpty()) {
|
||||
return roots[0].list();
|
||||
final String[] list = roots[0].list();
|
||||
return list != null ? list : ArrayUtil.EMPTY_STRING_ARRAY;
|
||||
}
|
||||
if (file.getName().isEmpty()) {
|
||||
// return drive letter names for the 'fake' root on windows
|
||||
|
||||
Reference in New Issue
Block a user