timedate: use SymlinkFlags enum members for flags
The flags to pass to symlinkat_atomic_full are defined in the SymlinkFlags enum type. The previous code passed the result of a boolean check operation directly instead of using flags. Be explicit about the value to pass instead of relying on true corresponding to the enum value for the SYMLINK_MAKE_RELATIVE flag. Signed-off-by: Daniel Wagenknecht <dwagenknecht@emlix.com>
This commit is contained in:
committed by
Lennart Poettering
parent
b1cb951a6f
commit
d8b9dacaf9
@@ -312,7 +312,7 @@ static int context_write_data_timezone(Context *c) {
|
||||
}
|
||||
|
||||
return symlinkat_atomic_full(source, AT_FDCWD, etc_localtime(),
|
||||
!secure_getenv("SYSTEMD_ETC_LOCALTIME"));
|
||||
!secure_getenv("SYSTEMD_ETC_LOCALTIME") ? SYMLINK_MAKE_RELATIVE : 0);
|
||||
}
|
||||
|
||||
static const char* etc_adjtime(void) {
|
||||
|
||||
Reference in New Issue
Block a user