]> git.ipfire.org Git - thirdparty/systemd.git/commit
copy: Invoke hardlink context cleanup before restoring timestamps
authorAndreas Stührk <andreas.stuehrk@yaxi.tech>
Tue, 25 Feb 2025 23:05:41 +0000 (00:05 +0100)
committerLennart Poettering <lennart@poettering.net>
Wed, 26 Feb 2025 08:07:26 +0000 (09:07 +0100)
commitb66291444b8d4022ce68121af8e6f99d29ebefd0
tree81a4417159fb876ce0fa12805f37d899310c64e2
parent441dce159bb92bd70f4149147cb57a28eb9d7e2b
copy: Invoke hardlink context cleanup before restoring timestamps

When hardlink recreation is requested, it creates temporary files that
will be deleted once the context is destroyed. The deletion
(potentially) updates the directory's timestamps, so it's crucial that
the deletion happens before the directory timestamps are restored when
`COPY_RESTORE_DIRECTORY_TIMESTAMPS` is requested.
src/shared/copy.c