From 9c28ccac4ac51c29d57c160eea62dfa8f51be42a Mon Sep 17 00:00:00 2001 From: sanghyuk Ko Date: Thu, 28 Mar 2013 11:03:25 +0900 Subject: [PATCH] [Internal: debug log add] debug log add [Problem] - [Cause] - [Solution] - debug log add Change-Id: Iff1775e821461df5b9a5a5707e8eaafb2faff7e3 --- src/framework/event/oma_ds_api.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/src/framework/event/oma_ds_api.c b/src/framework/event/oma_ds_api.c index af5e068..2e94ba3 100755 --- a/src/framework/event/oma_ds_api.c +++ b/src/framework/event/oma_ds_api.c @@ -467,12 +467,13 @@ static int _launch_omads_agent(void) DBusGConnection *connection = NULL; DBusGProxy *dbus_proxy = NULL; + gboolean bResult = FALSE; g_type_init(); connection = dbus_g_bus_get(DBUS_BUS_SYSTEM, &error); if (error != NULL) { - _DEBUG_ERROR("Connecting to system bus failed: %s\n", error->message); + _DEBUG_ERROR("dbus_g_bus_get failed: %s\n", error->message); g_error_free(error); _INNER_FUNC_EXIT; return -1; @@ -484,7 +485,17 @@ static int _launch_omads_agent(void) _DEBUG_INFO("dbus_proxy %x", dbus_proxy); //dbus_g_proxy_call_no_reply(dbus_proxy, "Hello_Agent", G_TYPE_INVALID); - dbus_g_proxy_call(dbus_proxy, "Hello_Agent", &error, G_TYPE_INVALID, G_TYPE_INVALID); + bResult = dbus_g_proxy_call(dbus_proxy, "Hello_Agent", &error, G_TYPE_INVALID, G_TYPE_INVALID); + + if (bResult == FALSE) { + _DEBUG_ERROR("dbus_g_proxy_call failed: %s\n", error->message); + g_error_free(error); + g_object_unref(dbus_proxy); + dbus_g_connection_unref(connection); + + _INNER_FUNC_EXIT; + return -1; + } g_object_unref(dbus_proxy); dbus_g_connection_unref(connection); @@ -513,7 +524,7 @@ static int _kill_omads_agent(void) connection = dbus_g_bus_get(DBUS_BUS_SYSTEM, &error); if (error != NULL) { - _DEBUG_ERROR("Connecting to system bus failed: %s\n", error->message); + _DEBUG_ERROR("dbus_g_bus_get failed: %s\n", error->message); g_error_free(error); _INNER_FUNC_EXIT; return -1; -- 2.7.4