static gboolean terminated = FALSE;
static gboolean is_initialized = FALSE;
+static void __on_log_glib(const gchar *log_domain, GLogLevelFlags log_level,
+ const gchar *msg, gpointer user_data)
+{
+ BT_ERR_C("%s", msg);
+}
+
static void __bt_release_service(void)
{
_bt_service_unregister_vconf_handler();
+ _bt_service_unregister_poweroff_event();
_bt_service_adapter_le_deinit();
_bt_deinit_service_event_sender();
terminated = TRUE;
- BT_INFO_C("Terminating the bt-service daemon");
+ BT_INFO_C("### Terminating the bt-service daemon");
if (main_loop != NULL)
g_main_loop_quit(main_loop);
int ps_mode_deactivation = 0;
#endif
+ if (_is_name_acquired() == FALSE) {
+ BT_ERR("dbus name is NOT acquired yet");
+ return TRUE;
+ }
+
status = _bt_adapter_get_status();
le_status = _bt_adapter_get_le_status();
BT_DBG("State: %d, LE State: %d", status, le_status);
}
_bt_service_register_vconf_handler();
+ _bt_service_register_poweroff_event();
/* Event reciever Init */
ret = _bt_init_service_event_receiver();
return 0;
}
+ g_log_set_default_handler(__on_log_glib, NULL);
+
main_loop = g_main_loop_new(NULL, FALSE);
g_main_loop_run(main_loop);