1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-28 11:55:44 +03:00

nspawn: make sure the device type survives when setting device mode

This commit is contained in:
Frantisek Sumsal 2023-05-16 11:40:33 +02:00
parent f00519b5b3
commit cd70372b93

View File

@ -819,7 +819,7 @@ static int oci_device_file_mode(const char *name, JsonVariant *v, JsonDispatchFl
return json_log(v, flags, SYNTHETIC_ERRNO(ERANGE),
"fileMode out of range, refusing.");
*mode = m;
*mode = (*mode & ~07777) | m;
return 0;
}