Path.absolute()
will do the wrong thing, for example, if your path is /foo/../bar
and /foo
is really a symlink to /xyzzy/quux
. The actual path would be /xyzzy/bar
but Path.absolute()
will return you /bar
, which may point to a different file!
1 Like