mount: block creation of mount units for API file systems
This commit is contained in:
parent
33bd08a97a
commit
33ff02c9fe
2
TODO
2
TODO
|
@ -26,8 +26,6 @@ F15:
|
||||||
|
|
||||||
* reload-or-try-restart man page blurb uses word "fail"
|
* reload-or-try-restart man page blurb uses word "fail"
|
||||||
|
|
||||||
* explicitly block creation of mount units for API file systems
|
|
||||||
|
|
||||||
Features:
|
Features:
|
||||||
|
|
||||||
* write blog stories about:
|
* write blog stories about:
|
||||||
|
|
|
@ -476,6 +476,11 @@ static int mount_verify(Mount *m) {
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (mount_point_is_api(m->where) || mount_point_ignore(m->where)) {
|
||||||
|
log_error("Cannot create mount unit for API file system %s. Refusing.", m->where);
|
||||||
|
return -EINVAL;
|
||||||
|
}
|
||||||
|
|
||||||
if (m->meta.fragment_path && !m->parameters_fragment.what) {
|
if (m->meta.fragment_path && !m->parameters_fragment.what) {
|
||||||
log_error("%s's What setting is missing. Refusing.", m->meta.id);
|
log_error("%s's What setting is missing. Refusing.", m->meta.id);
|
||||||
return -EBADMSG;
|
return -EBADMSG;
|
||||||
|
@ -1300,9 +1305,7 @@ static int mount_add_one(
|
||||||
|
|
||||||
/* Ignore API mount points. They should never be referenced in
|
/* Ignore API mount points. They should never be referenced in
|
||||||
* dependencies ever. */
|
* dependencies ever. */
|
||||||
if (mount_point_is_api(where))
|
if (mount_point_is_api(where) || mount_point_ignore(where))
|
||||||
return 0;
|
|
||||||
if (mount_point_ignore(where))
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
if (streq(fstype, "autofs"))
|
if (streq(fstype, "autofs"))
|
||||||
|
|
Loading…
Reference in New Issue