mirror of
https://github.com/AuxXxilium/eudev.git
synced 2025-03-08 22:35:10 +07:00
job: when converting restart jobs, move them to WAITING state
This commit is contained in:
parent
46d95c0fe0
commit
9c2d9caab2
@ -461,7 +461,6 @@ int job_finish_and_invalidate(Job *j, bool success) {
|
|||||||
assert(j);
|
assert(j);
|
||||||
assert(j->installed);
|
assert(j->installed);
|
||||||
|
|
||||||
log_debug("Job %s/%s finished, success=%s", j->unit->meta.id, job_type_to_string(j->type), yes_no(success));
|
|
||||||
job_add_to_dbus_queue(j);
|
job_add_to_dbus_queue(j);
|
||||||
|
|
||||||
/* Patch restart jobs so that they become normal start jobs */
|
/* Patch restart jobs so that they become normal start jobs */
|
||||||
@ -471,13 +470,15 @@ int job_finish_and_invalidate(Job *j, bool success) {
|
|||||||
j->unit->meta.id, job_type_to_string(j->type),
|
j->unit->meta.id, job_type_to_string(j->type),
|
||||||
j->unit->meta.id, job_type_to_string(JOB_START));
|
j->unit->meta.id, job_type_to_string(JOB_START));
|
||||||
|
|
||||||
j->state = JOB_RUNNING;
|
j->state = JOB_WAITING;
|
||||||
j->type = JOB_START;
|
j->type = JOB_START;
|
||||||
|
|
||||||
job_add_to_run_queue(j);
|
job_add_to_run_queue(j);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
log_debug("Job %s/%s finished, success=%s", j->unit->meta.id, job_type_to_string(j->type), yes_no(success));
|
||||||
|
|
||||||
j->failed = !success;
|
j->failed = !success;
|
||||||
u = j->unit;
|
u = j->unit;
|
||||||
t = j->type;
|
t = j->type;
|
||||||
|
Loading…
Reference in New Issue
Block a user