summaryrefslogtreecommitdiff
path: root/src/firstboot
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2021-03-04 18:52:10 +0100
committerLuca Boccassi <luca.boccassi@gmail.com>2021-03-04 22:35:52 +0000
commitbb72c434854f9f76f773edcb1f4b036372f5dc96 (patch)
tree57c8336e6251f3a36db22cb0366a8e4d131a8cf7 /src/firstboot
parente1aec57dd19e875c4a06105716859213a875601a (diff)
downloadsystemd-bb72c434854f9f76f773edcb1f4b036372f5dc96.tar.gz
copy: move sync_rights() to copy.c and rename copy_rights()
It's so similar to copy_access(), hence let's move it over and rename it in similar style to the rest of the functions. No change in behaviour, just moving things over.
Diffstat (limited to 'src/firstboot')
-rw-r--r--src/firstboot/firstboot.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/firstboot/firstboot.c b/src/firstboot/firstboot.c
index c0e88e7915..8cd5e28532 100644
--- a/src/firstboot/firstboot.c
+++ b/src/firstboot/firstboot.c
@@ -675,7 +675,7 @@ static int write_root_passwd(const char *passwd_path, const char *password, cons
if (original) {
struct passwd *i;
- r = sync_rights(fileno(original), fileno(passwd));
+ r = copy_rights(fileno(original), fileno(passwd));
if (r < 0)
return r;
@@ -743,7 +743,7 @@ static int write_root_shadow(const char *shadow_path, const char *hashed_passwor
if (original) {
struct spwd *i;
- r = sync_rights(fileno(original), fileno(shadow));
+ r = copy_rights(fileno(original), fileno(shadow));
if (r < 0)
return r;