From 1d2017553fb54c7ad08f0d5419aea3b4ef5c7fcf Mon Sep 17 00:00:00 2001 From: Deokhyun Kim Date: Thu, 26 Oct 2017 19:30:14 +0900 Subject: [PATCH] Use device_address instead of bluetooth_hid_request_t Change-Id: I60759a6c5973644f7b7622324c65bdae4f918e4f Signed-off-by: Deokhyun Kim Signed-off-by: DoHyun Pyun --- src/bluetooth-common.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/bluetooth-common.c b/src/bluetooth-common.c index 4631f35..045bd9a 100644 --- a/src/bluetooth-common.c +++ b/src/bluetooth-common.c @@ -1123,7 +1123,6 @@ static void __bt_event_proxy(int event, bluetooth_event_param_t *param, void *us int *adv_handle; bluetooth_rfcomm_connection_t *connection_ind = NULL; bluetooth_rfcomm_disconnection_t *disconnection_ind = NULL; - bluetooth_hid_request_t *hid_connection_status = NULL; bt_socket_connection_s rfcomm_connection; bt_device_sdp_info_s *sdp_info = NULL; bt_device_connection_info_s *conn_info = NULL; @@ -1987,9 +1986,8 @@ static void __bt_event_proxy(int event, bluetooth_event_param_t *param, void *us break; case BLUETOOTH_HID_DEVICE_CONNECTED: BT_INFO("BLUETOOTH_HID_DEVICE_CONNECTED"); - hid_connection_status = (bluetooth_hid_request_t *)(param->param_data); - _bt_convert_address_to_string(&device_addr, - &(hid_connection_status->device_addr)); + bd_addr = (bluetooth_device_address_t *)(param->param_data); + _bt_convert_address_to_string(&device_addr, bd_addr); ((bt_hid_device_connection_state_changed_cb)bt_event_slot_container[event_index].callback) (_bt_get_error_code(param->result), TRUE, device_addr, bt_event_slot_container[event_index].user_data); @@ -1997,9 +1995,8 @@ static void __bt_event_proxy(int event, bluetooth_event_param_t *param, void *us break; case BLUETOOTH_HID_DEVICE_DISCONNECTED: BT_INFO("BLUETOOTH_HID_DEVICE_DISCONNECTED"); - hid_connection_status = (bluetooth_hid_request_t *)(param->param_data); - _bt_convert_address_to_string(&device_addr, - &(hid_connection_status->device_addr)); + bd_addr = (bluetooth_device_address_t *)(param->param_data); + _bt_convert_address_to_string(&device_addr, bd_addr); ((bt_hid_device_connection_state_changed_cb)bt_event_slot_container[event_index].callback) (_bt_get_error_code(param->result), FALSE, device_addr, bt_event_slot_container[event_index].user_data); -- 2.34.1