[PATCH 02/12] dbus-core: Attempt to connect to dbus ASAP

Hans de Goede hdegoede at redhat.com
Wed Jan 15 06:32:16 PST 2014


For systemd-logind integration we need the dbus connection to be available
before enumerating input and gfx devices.

Signed-off-by: Hans de Goede <hdegoede at redhat.com>
---
 hw/xfree86/common/dbus-core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/xfree86/common/dbus-core.c b/hw/xfree86/common/dbus-core.c
index 43d6281..b0fd92d 100644
--- a/hw/xfree86/common/dbus-core.c
+++ b/hw/xfree86/common/dbus-core.c
@@ -233,8 +233,8 @@ dbus_core_init(void)
     memset(&bus_info, 0, sizeof(bus_info));
     bus_info.fd = -1;
     bus_info.hooks = NULL;
-    bus_info.connection = NULL;
-    bus_info.timer = TimerSet(NULL, 0, 1, reconnect_timer, NULL);
+    if (!connect_to_bus())
+        bus_info.timer = TimerSet(NULL, 0, 1, reconnect_timer, NULL);
 
     return 1;
 }
-- 
1.8.4.2



More information about the xorg-devel mailing list