manager: fix connecting to bus when dbus is actually around (#7205)
authorMichal Sekletar <msekletar@users.noreply.github.com>
Wed, 1 Nov 2017 09:25:48 +0000 (02:25 -0700)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Wed, 1 Nov 2017 09:25:48 +0000 (10:25 +0100)
commit41dfa61d35c51a584437481d20541d5c3ccfa93d
treead01269e55680c057c2c63114920aa11e6daf849
parent723afa4f964aa3c7122cd218f631f692c08aa23f
manager: fix connecting to bus when dbus is actually around (#7205)

manager_connect_bus() is called *before* manager_coldplug(). As a last
thing in service_coldplug() we set service state to
s->deserialized_state, and thus before we do that all services are
inactive and try_connect always evaluates to false. To fix that we must
look at deserialized state instead of current unit state.

Fixes #7146
src/core/manager.c