service: add implicit dbus deps only for Type=dbus units
We want to be able to use BusName= in services that run during early boot already, and thus don't synthesize deps on dbus there. Instead add them when Type=dbus is set, because in that case we actually really need D-Bus support. Fixes: #17037
This commit is contained in:
parent
31d74c66e2
commit
a7f49f0b7c
|
@ -684,7 +684,7 @@ static int service_setup_bus_name(Service *s) {
|
|||
|
||||
assert(s);
|
||||
|
||||
if (!s->bus_name)
|
||||
if (s->type != SERVICE_DBUS)
|
||||
return 0;
|
||||
|
||||
r = unit_add_dependency_by_name(UNIT(s), UNIT_REQUIRES, SPECIAL_DBUS_SOCKET, true, UNIT_DEPENDENCY_FILE);
|
||||
|
|
Loading…
Reference in New Issue