From e062a44edd9f3f20bb13eb918ac7b8f963c45dab Mon Sep 17 00:00:00 2001 From: Luiz Augusto von Dentz Date: Tue, 29 Oct 2024 17:27:14 -0400 Subject: [PATCH] main: Add call to g_dbus_set_debug This adds a call to g_dbus_set_debug which enabled debugging of D-Bus messages when dynamic debug is enabled for main.c: bluetoothd[3672799]: [:1.38799:method_call] > org.bluez.Device1.Connect [#761] bluetoothd[3672799]: [:1.38799:error] < org.bluez.Error.Failed [#761] --- src/main.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/main.c b/src/main.c index 89ee6897c..41c3271a7 100644 --- a/src/main.c +++ b/src/main.c @@ -1322,6 +1322,11 @@ static void disconnected_dbus(DBusConnection *conn, void *data) mainloop_quit(); } +static void dbus_debug(const char *str, void *data) +{ + DBG_IDX(0xffff, "%s", str); +} + static int connect_dbus(void) { DBusConnection *conn; @@ -1343,6 +1348,7 @@ static int connect_dbus(void) g_dbus_set_disconnect_function(conn, disconnected_dbus, NULL, NULL); g_dbus_attach_object_manager(conn); + g_dbus_set_debug(dbus_debug, NULL, NULL); return 0; } -- 2.47.3