From a033d164a1eae7651577e2503c7b73c506409bd1 Mon Sep 17 00:00:00 2001 From: Mike Gorse Date: Thu, 6 Jan 2011 10:37:08 -0600 Subject: [PATCH] Fix some memory leaks --- atk-adaptor/bridge.c | 4 +++- atk-adaptor/event.c | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/atk-adaptor/bridge.c b/atk-adaptor/bridge.c index a1cfa90..e856c82 100644 --- a/atk-adaptor/bridge.c +++ b/atk-adaptor/bridge.c @@ -174,6 +174,7 @@ set_reply (DBusPendingCall *pending, void *user_data) void **replyptr = (void **)user_data; *replyptr = dbus_pending_call_steal_reply (pending); + dbus_pending_call_unref (pending); } /*---------------------------------------------------------------------------*/ @@ -247,7 +248,8 @@ register_reply (DBusPendingCall *pending, void *user_data) SpiBridge *app = user_data; DBusMessage *message; - reply = dbus_pending_call_steal_reply (pending); + reply = dbus_pending_call_steal_reply (pending); + dbus_pending_call_unref (pending); if (reply) { gchar *app_name, *obj_path; diff --git a/atk-adaptor/event.c b/atk-adaptor/event.c index 63cb9a5..cc1877a 100644 --- a/atk-adaptor/event.c +++ b/atk-adaptor/event.c @@ -72,6 +72,7 @@ set_reply (DBusPendingCall * pending, void *user_data) SpiReentrantCallClosure* closure = (SpiReentrantCallClosure *) user_data; closure->reply = dbus_pending_call_steal_reply (pending); + dbus_pending_call_unref (pending); switch_main_context (NULL); g_main_loop_quit (closure->loop); } -- 2.7.4