This fixes handling of symlinks that start with '..', and symlink targets that contain symlinks themselves.