summaryrefslogtreecommitdiff
path: root/job.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-05-16 03:57:07 +0200
committerLennart Poettering <lennart@poettering.net>2010-05-16 03:57:07 +0200
commit94b6dfa24f84bd8854c1dc566413b0719dce9e0d (patch)
tree58036dab36657dce62b5926a103232b8a907dbdf /job.c
parentc1b94fda55e6e29e388a30f846b62650b5e60f7e (diff)
unit,job: when we suppress a D-Bus signal because nobody is listening, don't delay it until later
Diffstat (limited to 'job.c')
-rw-r--r--job.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/job.c b/job.c
index 1d59bcb27f..887de92cad 100644
--- a/job.c
+++ b/job.c
@@ -541,6 +541,11 @@ void job_add_to_dbus_queue(Job *j) {
if (j->in_dbus_queue)
return;
+ if (set_isempty(j->manager->subscribed)) {
+ j->sent_dbus_new_signal = true;
+ return;
+ }
+
LIST_PREPEND(Job, dbus_queue, j->manager->dbus_job_queue, j);
j->in_dbus_queue = true;
}