diff options
author | Matteo Croce <teknoraver@meta.com> | 2024-07-09 02:05:29 +0200 |
---|---|---|
committer | Matteo Croce <teknoraver@meta.com> | 2024-07-16 15:03:37 +0200 |
commit | cfa477b6157fe1ab641e72439234929f7dbe159b (patch) | |
tree | 760a33db2b7a772bd9c558be109000ba0da58e39 /src/home | |
parent | homed: use O_PATH for FDs (diff) | |
download | systemd-cfa477b6157fe1ab641e72439234929f7dbe159b.tar.xz systemd-cfa477b6157fe1ab641e72439234929f7dbe159b.zip |
homed: open blob dir with O_PATH
`sys_base_dfd` is only used as dirfd argument to *_at functions,
open it with O_PATH.
Diffstat (limited to 'src/home')
-rw-r--r-- | src/home/homework-blob.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/home/homework-blob.c b/src/home/homework-blob.c index 6b22ab6f24..0ad2941539 100644 --- a/src/home/homework-blob.c +++ b/src/home/homework-blob.c @@ -218,7 +218,7 @@ int home_reconcile_blob_dirs(UserRecord *h, int root_fd, int reconciled) { if (reconciled == USER_RECONCILE_IDENTICAL) return 0; - sys_base_dfd = open(home_system_blob_dir(), O_RDONLY|O_DIRECTORY|O_CLOEXEC|O_NOFOLLOW); + sys_base_dfd = open(home_system_blob_dir(), O_PATH|O_DIRECTORY|O_CLOEXEC|O_NOFOLLOW); if (sys_base_dfd < 0) return log_error_errno(errno, "Failed to open system blob dir: %m"); |