Skip to content

Commit eefe880

Browse files
committed
Evaluate symlinks in paths passed in as user arguments
1 parent 4c15e83 commit eefe880

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

filesystems.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@ func findMounts(mounts []Mount, path string) ([]Mount, error) {
1313
return nil, err
1414
}
1515

16+
path, err = filepath.EvalSymlinks(path)
17+
if err != nil {
18+
return nil, err
19+
}
20+
1621
_, err = os.Stat(path)
1722
if err != nil {
1823
return nil, err

0 commit comments

Comments
 (0)