summaryrefslogtreecommitdiff
path: root/src/job.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-09-23 15:38:42 +0200
committerLennart Poettering <lennart@poettering.net>2010-09-23 15:38:42 +0200
commit76bf48b7d09b6e22d1952ac2fa07fec8ee501b76 (patch)
treea1b29cd56327310d713e6e557ef8eb1e7aab2dca /src/job.c
parent22be093ffb403a1c474037939ca9b88b1ee39f77 (diff)
dbus: export number of total failed jobs on D-Bus interface
Diffstat (limited to 'src/job.c')
-rw-r--r--src/job.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/job.c b/src/job.c
index ac3bb9d729..c219b0d18b 100644
--- a/src/job.c
+++ b/src/job.c
@@ -478,9 +478,13 @@ int job_finish_and_invalidate(Job *j, bool success) {
return 0;
}
+ j->failed = !success;
+
log_debug("Job %s/%s finished, success=%s", j->unit->meta.id, job_type_to_string(j->type), yes_no(success));
- j->failed = !success;
+ if (j->failed)
+ j->manager->n_failed_jobs ++;
+
u = j->unit;
t = j->type;
job_free(j);