From: Anuj Jain Date: Mon, 4 Apr 2022 12:46:59 +0000 (+0530) Subject: LE CoC: Fix disconnection on multiple writes X-Git-Tag: submit/tizen/20220419.002419~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0aee08267fc6fe50cb14956bfb713277ce6d5097;p=platform%2Fcore%2Fapi%2Fbluetooth.git LE CoC: Fix disconnection on multiple writes This patch fixes the the issue of LE_L2CAP socket disconnection when write operation is performed more than once by either client or server. Change-Id: I6bd2e7fdbfe8ba1931d4a141266da8c902deb228 Signed-off-by: Anuj Jain --- diff --git a/tests/test/bt_unit_test.c b/tests/test/bt_unit_test.c index 9f7299d..e2ba197 100644 --- a/tests/test/bt_unit_test.c +++ b/tests/test/bt_unit_test.c @@ -6237,12 +6237,12 @@ int test_input_callback(void *data) if (g_test_param.param_count > 0) { ret = bt_socket_send_data_l2cap_channel(l2cap_le_client_fd, g_test_param.params[0], - strlen(g_test_param.params[0]) + 1); + strlen(g_test_param.params[0])); __bt_free_test_param(&g_test_param); } else { ret = bt_socket_send_data_l2cap_channel(l2cap_le_client_fd, - data, sizeof(data)); + data, strlen(data)); } TC_PRT("returns %d %s\n", ret, __bt_get_error_message(ret));