diff options
Diffstat (limited to 'swaybar')
-rw-r--r-- | swaybar/tray/dbus.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/swaybar/tray/dbus.c b/swaybar/tray/dbus.c index 333d398e..22531aa6 100644 --- a/swaybar/tray/dbus.c +++ b/swaybar/tray/dbus.c | |||
@@ -158,6 +158,12 @@ int dbus_init() { | |||
158 | dbus_error_init(&error); | 158 | dbus_error_init(&error); |
159 | 159 | ||
160 | conn = dbus_bus_get(DBUS_BUS_SESSION, &error); | 160 | conn = dbus_bus_get(DBUS_BUS_SESSION, &error); |
161 | if (conn == NULL) { | ||
162 | sway_log(L_INFO, "Compiled with dbus support, but unable to connect to dbus"); | ||
163 | sway_log(L_INFO, "swaybar will be unable to display tray icons."); | ||
164 | return -1; | ||
165 | } | ||
166 | |||
161 | dbus_connection_set_exit_on_disconnect(conn, FALSE); | 167 | dbus_connection_set_exit_on_disconnect(conn, FALSE); |
162 | if (dbus_error_is_set(&error)) { | 168 | if (dbus_error_is_set(&error)) { |
163 | sway_log(L_ERROR, "Cannot get bus connection: %s\n", error.message); | 169 | sway_log(L_ERROR, "Cannot get bus connection: %s\n", error.message); |