summaryrefslogtreecommitdiff
path: root/src/core/job.c
diff options
context:
space:
mode:
authorMichal Schmidt <mschmidt@redhat.com>2012-04-20 10:02:05 +0200
committerMichal Schmidt <mschmidt@redhat.com>2012-04-20 17:12:29 +0200
commitd6a093d098054b6fe866441251ad9485c9e31584 (patch)
treeb777bc38e26e52c62c676b7f1ce25319a33e1eb9 /src/core/job.c
parent656bbffc6c45bdd8d5c28a96ca948ba16c546547 (diff)
transaction: remove checks for installed
Transactions cannot contain installed jobs anymore. Remove the now pointless checks.
Diffstat (limited to 'src/core/job.c')
-rw-r--r--src/core/job.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/core/job.c b/src/core/job.c
index 3454ffd1db..436f4a1b35 100644
--- a/src/core/job.c
+++ b/src/core/job.c
@@ -83,14 +83,13 @@ void job_free(Job *j) {
void job_uninstall(Job *j) {
assert(j->installed);
+ assert(j->unit->job == j);
/* Detach from next 'bigger' objects */
bus_job_send_removed_signal(j);
- if (j->unit->job == j) {
- j->unit->job = NULL;
- unit_add_to_gc_queue(j->unit);
- }
+ j->unit->job = NULL;
+ unit_add_to_gc_queue(j->unit);
hashmap_remove(j->manager->jobs, UINT32_TO_PTR(j->id));
j->installed = false;