assert(u);
assert(u->load_state == UNIT_STUB);
- s->timeout_stop_usec = DEFAULT_TIMEOUT_USEC;
+ s->timeout_stop_usec = u->manager->default_timeout_stop_usec;
watch_init(&s->timer_watch);
assert(s);
+ if (s->state == SCOPE_FAILED)
+ return -EPERM;
+
if (s->state == SCOPE_STOP_SIGTERM ||
s->state == SCOPE_STOP_SIGKILL)
return -EAGAIN;
return r;
}
- r = cg_attach_many_with_mask(u->cgroup_mask, u->cgroup_path, s->pids);
+ r = cg_attach_many_everywhere(u->manager->cgroup_supported, u->cgroup_path, s->pids);
if (r < 0)
return r;