mirror of
https://github.com/systemd/systemd.git
synced 2024-11-02 19:21:53 +03:00
scope: don't require an initialized PIDs set when deserializing
When a scope unit is created due to deserialization rather than client request don't enforce that the PIDs set must be non-empty, since the cgroup is already populated.
This commit is contained in:
parent
b170dd803d
commit
0c5778a26b
@ -112,7 +112,7 @@ static int scope_verify(Scope *s) {
|
||||
if (UNIT(s)->load_state != UNIT_LOADED)
|
||||
return 0;
|
||||
|
||||
if (set_size(s->pids) <= 0) {
|
||||
if (set_size(s->pids) <= 0 && UNIT(s)->manager->n_reloading <= 0) {
|
||||
log_error_unit(UNIT(s)->id, "Scope %s has no PIDs. Refusing.", UNIT(s)->id);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user