From 1136b929bd497edd215a79050c0d9987c38479ea Mon Sep 17 00:00:00 2001 From: Sangyoon Jang Date: Fri, 4 Sep 2015 16:03:46 +0900 Subject: [PATCH] Fix closing dbus connection the connection should be freed using g_object_unref Change-Id: I6f742bf3ca57b493949272ee2120325b312a1913 Signed-off-by: Sangyoon Jang --- comm/pkgmgr_installer.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/comm/pkgmgr_installer.c b/comm/pkgmgr_installer.c index 4d4a219..4053b47 100644 --- a/comm/pkgmgr_installer.c +++ b/comm/pkgmgr_installer.c @@ -187,8 +187,10 @@ API int pkgmgr_installer_free(pkgmgr_installer *pi) if (pi->caller_pkgid) free(pi->caller_pkgid); - if (pi->conn) - g_dbus_connection_close_sync(pi->conn, NULL, NULL); + if (pi->conn) { + g_dbus_connection_flush_sync(pi->conn, NULL, NULL); + g_object_unref(pi->conn); + } free(pi); -- 2.7.4