refactor(apple): normalize host paths at the filesystem boundary
This commit is contained in:
@@ -37,13 +37,8 @@ export const resolveTreePath = async (
|
||||
if (entry.kind === "symlink") {
|
||||
hops += 1;
|
||||
if (hops > MAX_SYMLINK_HOPS) return { kind: "absent" };
|
||||
if (
|
||||
entry.target.startsWith("/") ||
|
||||
/^[a-zA-Z]:[\\/]/u.test(entry.target) ||
|
||||
entry.target.startsWith("\\\\") ||
|
||||
entry.target.startsWith("//")
|
||||
)
|
||||
return { kind: "escapes" };
|
||||
// Tree providers convert host link syntax to this POSIX namespace.
|
||||
if (entry.target.startsWith("/")) return { kind: "escapes" };
|
||||
pending.unshift(...segmentsOf(entry.target));
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user