Change path resolution to remove parent directories without following
symbolic links.
When resolving relative paths such as `../../storage/emulated/0/`
the symlinks will be read and parent paths removed, in that order.
This results in paths from an `/sdcard` symlink producing unexpected
relative paths e.g.`/sdcard/../storage/emulated/0/test.mp3` resolves to
`/storage/emulated/storage/emulated/0/test.mp3` instead of
`/storage/emulated/0/test.mp3`.