From 9a3271cdeab420123b77157822fa7fe247deb025 Mon Sep 17 00:00:00 2001 From: Vinicius Costa Gomes Date: Wed, 29 Oct 2008 11:54:17 -0300 Subject: [PATCH] obexd: Removes the agent watch if the agent is released --- obexd/client/session.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/obexd/client/session.c b/obexd/client/session.c index 74428f87a..24322dbf2 100644 --- a/obexd/client/session.c +++ b/obexd/client/session.c @@ -635,6 +635,11 @@ static DBusMessage *release_agent(DBusConnection *connection, g_free(session->agent_path); session->agent_path = NULL; + if (session->agent_watch) { + g_dbus_remove_watch(session->conn, session->agent_watch); + session->agent_watch = 0; + } + return dbus_message_new_method_return(message); } -- 2.47.3