From: Lennart Poettering Date: Wed, 14 Nov 2018 12:00:12 +0000 (+0100) Subject: core: drop dbus queue recursion check X-Git-Tag: v240~322 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3dafa6bc7636451e49565f6260c531c0304285f6;p=thirdparty%2Fsystemd.git core: drop dbus queue recursion check We don't dispatch the queue recursively anymore, hence let's simplify things a bit. As pointed out by @fbuihuu: https://github.com/systemd/systemd/pull/10763#discussion_r233209550 --- diff --git a/src/core/manager.c b/src/core/manager.c index a7ee6a6523c..d7dbf6c8a97 100644 --- a/src/core/manager.c +++ b/src/core/manager.c @@ -2157,10 +2157,6 @@ static unsigned manager_dispatch_dbus_queue(Manager *m) { assert(m); - /* Avoid recursion */ - if (m->dispatching_dbus_queue) - return 0; - /* When we are reloading, let's not wait with generating signals, since we need to exit the manager as quickly * as we can. There's no point in throttling generation of signals in that case. */ if (MANAGER_IS_RELOADING(m) || m->send_reloading_done || m->pending_reload_message) @@ -2189,8 +2185,6 @@ static unsigned manager_dispatch_dbus_queue(Manager *m) { budget = MANAGER_BUS_MESSAGE_BUDGET; } - m->dispatching_dbus_queue = true; - while (budget != 0 && (u = m->dbus_unit_queue)) { assert(u->in_dbus_queue); @@ -2212,8 +2206,6 @@ static unsigned manager_dispatch_dbus_queue(Manager *m) { budget--; } - m->dispatching_dbus_queue = false; - if (m->send_reloading_done) { m->send_reloading_done = false; bus_manager_send_reloading(m, false); diff --git a/src/core/manager.h b/src/core/manager.h index 1977735da1d..b65c4c8451f 100644 --- a/src/core/manager.h +++ b/src/core/manager.h @@ -287,7 +287,6 @@ struct Manager { /* Flags */ bool dispatching_load_queue:1; - bool dispatching_dbus_queue:1; bool taint_usr:1;