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

mount: make checks on perpetual mount units more lax

We don#t really care where perpetual mounts are mounted from, since they
have to exist since before we run anyway.
This commit is contained in:
Lennart Poettering 2020-01-17 15:09:01 +01:00
parent 88414eed6f
commit 0879fbd6fe

View File

@ -537,10 +537,9 @@ static int mount_verify(Mount *m) {
}
p = get_mount_parameters_fragment(m);
if (p && !p->what) {
log_unit_error(UNIT(m), "What= setting is missing. Refusing.");
return -ENOEXEC;
}
if (p && !p->what && !UNIT(m)->perpetual)
return log_unit_error_errno(UNIT(m), SYNTHETIC_ERRNO(ENOEXEC),
"What= setting is missing. Refusing.");
if (m->exec_context.pam_name && m->kill_context.kill_mode != KILL_CONTROL_GROUP) {
log_unit_error(UNIT(m), "Unit has PAM enabled. Kill mode must be set to control-group'. Refusing.");