Skip to content

Commit e284be8

Browse files
committed
remove workaround for TruffleFile.isSymlink
1 parent bb6f328 commit e284be8

File tree

1 file changed

+2
-12
lines changed

1 file changed

+2
-12
lines changed

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/PosixModuleBuiltins.java

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -445,18 +445,8 @@ Object stat(String path, boolean followSymlinks) {
445445
} else if (f.isSymbolicLink()) {
446446
mode |= S_IFLNK;
447447
} else {
448-
// TODO: remove the additional check for symlink once GR-13265 is fixed
449-
TruffleFile canonicalFile = null;
450-
try {
451-
canonicalFile = f.getCanonicalFile();
452-
} catch (IOException e) {
453-
}
454-
if (!f.getAbsoluteFile().equals(canonicalFile)) {
455-
mode |= S_IFLNK;
456-
} else {
457-
// TODO: differentiate these
458-
mode |= S_IFSOCK | S_IFBLK | S_IFCHR | S_IFIFO;
459-
}
448+
// TODO: differentiate these
449+
mode |= S_IFSOCK | S_IFBLK | S_IFCHR | S_IFIFO;
460450
}
461451
try {
462452
mtime = fileTimeToSeconds(f.getLastModifiedTime(linkOptions));

0 commit comments

Comments
 (0)