transaction: do not add installed jobs to the transaction

Do not attempt to optimize away the job creation by refering to installed jobs.
We do not want to disturb installed jobs until commiting the transaction.

(A later patch to job merging will make the separation of transaction jobs and
installed jobs complete.)
This commit is contained in:
Michal Schmidt
2012-04-20 17:12:28 +02:00
parent 1da4264fbd
commit 3c956cfee2
+3 -7
View File
@@ -760,13 +760,9 @@ static Job* transaction_add_one_job(Transaction *tr, JobType type, Unit *unit, b
}
}
if (unit->job && unit->job->type == type)
j = unit->job;
else {
j = job_new(unit, type);
if (!j)
return NULL;
}
j = job_new(unit, type);
if (!j)
return NULL;
j->generation = 0;
j->marker = NULL;