transaction: add starting requirements for JOB_RESTART
While having a Requires= dependency between units, the dependency is started automatically on "systemctl start", but it's not started on "systemctl restart". JOB_RESTART jobs did not pull the dependencies for starting into the transaction. https://bugzilla.redhat.com/show_bug.cgi?id=802770 Note that the other bug noted in comment #2 has been fixed already by avoiding the deletion of anchor jobs.
This commit is contained in:
parent
97e6a11996
commit
6530407524
|
@ -866,7 +866,7 @@ int transaction_add_job_and_dependencies(
|
|||
}
|
||||
|
||||
/* Finally, recursively add in all dependencies. */
|
||||
if (type == JOB_START || type == JOB_RELOAD_OR_START) {
|
||||
if (type == JOB_START || type == JOB_RELOAD_OR_START || type == JOB_RESTART) {
|
||||
SET_FOREACH(dep, ret->unit->dependencies[UNIT_REQUIRES], i) {
|
||||
r = transaction_add_job_and_dependencies(tr, JOB_START, dep, ret, true, override, false, false, ignore_order, e);
|
||||
if (r < 0) {
|
||||
|
|
Loading…
Reference in a new issue