// Repeats infinitely
02-14 11:48:12.591+0900 E/BLUETOOTH_FRWK_API(P 4373, T 4373): bt-rfcomm-client.c: __client_data_received_cb(353) > IO Channel read is failed with 2
02-14 11:48:13.667+0900 E/BLUETOOTH_FRWK_API(P 4373, T 4373): bt-rfcomm-client.c: __client_data_received_cb(353) > IO Channel read is failed with 2
...........
02-14 11:48:24.251+0900 E/BLUETOOTH_FRWK_API(P 4373, T 4373): bt-rfcomm-client.c: __client_data_received_cb(353) > IO Channel read is failed with 2
02-14 11:48:24.251+0900 E/BLUETOOTH_FRWK_API(P 4373, T 4373): bt-rfcomm-client.c: __client_data_received_cb(353) > IO Channel read is failed with 2
Change-Id: Ifb630b340a8eabbe4781239b580e9242c99bf899
Signed-off-by: Deokhyun Kim <dukan.kim@samsung.com>
BT_ERR("IO Channel read is failed with %d", status);
g_free(buffer);
- if (err) {
- BT_ERR("IO Channel read error [%s]", err->message);
- if (status == G_IO_STATUS_ERROR &&
- __is_error_by_disconnect(err)) {
+ if (err || status == G_IO_STATUS_EOF) {
+ if (err)
+ BT_ERR("IO Channel read error [%s]", err->message);
+ if ((status == G_IO_STATUS_EOF) ||
+ (status == G_IO_STATUS_ERROR &&
+ __is_error_by_disconnect(err))) {
+
BT_ERR("cond : %d", cond);
- g_error_free(err);
+ if (err)
+ g_error_free(err);
conn_info = __get_conn_info_from_fd(info, fd);
if (conn_info == NULL) {
__rfcomm_client_disconnect(info);
return FALSE;
}
- g_error_free(err);
+ if (err)
+ g_error_free(err);
}
return TRUE;
}