Commit Graph

1 Commits

Author SHA1 Message Date
Ondrej Dubaj
e317168602 Fix following symlinks when processing the fixup list
The previous fix in b41daecb5 was incomplete. Fixup entries are
given the original path without calling cleanup_pathname().
To make sure we don't follow a symlink, we must strip trailing
slashes from the path.

The fixup entries are always directories. Make sure we try to modify
only directories by providing O_DIRECTORY to open() (if supported)
and if it fails to check directory via lstat().

Resolves: #1996634
2021-09-07 08:29:29 +00:00