summaryrefslogtreecommitdiff
path: root/navit/binding
diff options
context:
space:
mode:
authormartin-s <martin-s@ffa7fe5e-494d-0410-b361-a75ebd5db220>2010-05-12 09:06:18 +0000
committermartin-s <martin-s@ffa7fe5e-494d-0410-b361-a75ebd5db220>2010-05-12 09:06:18 +0000
commit56065302d83f8cf6284d72016ca428fdd4e72b10 (patch)
tree7b9f1afe30c8394e306da8a811b4d870a199a62e /navit/binding
parent6c4f3ff463df27373e0c9349dd8490bf642fe734 (diff)
downloadnavit-56065302d83f8cf6284d72016ca428fdd4e72b10.tar.gz
Add:binding_dbus:Configure option to use system bus
git-svn-id: http://svn.code.sf.net/p/navit/code/trunk/navit@3237 ffa7fe5e-494d-0410-b361-a75ebd5db220
Diffstat (limited to 'navit/binding')
-rw-r--r--navit/binding/dbus/binding_dbus.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/navit/binding/dbus/binding_dbus.c b/navit/binding/dbus/binding_dbus.c
index 762dd6c01..1a394da49 100644
--- a/navit/binding/dbus/binding_dbus.c
+++ b/navit/binding/dbus/binding_dbus.c
@@ -1744,7 +1744,11 @@ void plugin_init(void)
object_count=g_hash_table_new(g_str_hash, g_str_equal);
dbg(0,"enter 1\n");
dbus_error_init(&error);
+#ifdef DBUS_USE_SYSTEM_BUS
+ connection = dbus_bus_get(DBUS_BUS_SYSTEM, &error);
+#else
connection = dbus_bus_get(DBUS_BUS_SESSION, &error);
+#endif
if (!connection) {
dbg(0,"Failed to open connection to session message bus: %s\n", error.message);
dbus_error_free(&error);