diff options
author | Lennart Poettering <lennart@poettering.net> | 2021-11-24 18:31:51 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2021-11-24 18:31:51 +0100 |
commit | 6f2c813667018cc54f127a15a578a74071b0fa24 (patch) | |
tree | 8a680e0082ce966e94b070f36f64533d1839822d /src/home/homework.h | |
parent | homework: fix message typo (diff) | |
download | systemd-6f2c813667018cc54f127a15a578a74071b0fa24.tar.xz systemd-6f2c813667018cc54f127a15a578a74071b0fa24.zip |
homework: don't try to shift uidmap for already activated home areas
When we want to operate on an already activated home area we so far
tried to reapply the uidmapping logic. We shouldn't do that, it's
already applied after all.
We only want to apply this for newly activated home areas. Hence check
for the right HomeSetupFlags flag for it HOME_SETUP_ALREADY_ACTIVATED.
The patch is actually in theory a two-liner. Except that so far we don#t
pass the HomeSetupFlags flags down all necessary functions where the
uidmap stuff will eventually run. Hence this larger than intended
commit.
Diffstat (limited to '')
-rw-r--r-- | src/home/homework.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/home/homework.h b/src/home/homework.h index 750ad331c8..882a3f500b 100644 --- a/src/home/homework.h +++ b/src/home/homework.h @@ -80,9 +80,9 @@ int keyring_unlink(key_serial_t k); int home_setup(UserRecord *h, HomeSetupFlags flags, HomeSetup *setup, PasswordCache *cache, UserRecord **ret_header_home); -int home_refresh(UserRecord *h, HomeSetup *setup, UserRecord *header_home, PasswordCache *cache, struct statfs *ret_statfs, UserRecord **ret_new_home); +int home_refresh(UserRecord *h, HomeSetupFlags flags, HomeSetup *setup, UserRecord *header_home, PasswordCache *cache, struct statfs *ret_statfs, UserRecord **ret_new_home); -int home_maybe_shift_uid(UserRecord *h, HomeSetup *setup); +int home_maybe_shift_uid(UserRecord *h, HomeSetupFlags flags, HomeSetup *setup); int home_populate(UserRecord *h, int dir_fd); int home_load_embedded_identity(UserRecord *h, int root_fd, UserRecord *header_home, UserReconcileMode mode, PasswordCache *cache, UserRecord **ret_embedded_home, UserRecord **ret_new_home); |