Loading system/stack/gatt/gatt_cl.cc +35 −34 Original line number Diff line number Diff line Loading @@ -79,10 +79,14 @@ uint16_t disc_type_to_uuid[GATT_DISC_MAX] = { ******************************************************************************/ void gatt_act_discovery(tGATT_CLCB* p_clcb) { uint8_t op_code = disc_type_to_att_opcode[p_clcb->op_subtype]; tGATT_CL_MSG cl_req; tGATT_STATUS st; if (p_clcb->s_handle <= p_clcb->e_handle && p_clcb->s_handle != 0) { if (p_clcb->s_handle > p_clcb->e_handle || p_clcb->s_handle == 0) { /* end of handle range */ gatt_end_operation(p_clcb, GATT_SUCCESS, NULL); return; } tGATT_CL_MSG cl_req; memset(&cl_req, 0, sizeof(tGATT_CL_MSG)); cl_req.browse.s_handle = p_clcb->s_handle; Loading Loading @@ -112,13 +116,10 @@ void gatt_act_discovery(tGATT_CLCB* p_clcb) { size); } st = attp_send_cl_msg(*p_clcb->p_tcb, p_clcb, op_code, &cl_req); tGATT_STATUS st = attp_send_cl_msg(*p_clcb->p_tcb, p_clcb, op_code, &cl_req); if (st != GATT_SUCCESS && st != GATT_CMD_STARTED) { gatt_end_operation(p_clcb, GATT_ERROR, NULL); } } else /* end of handle range */ gatt_end_operation(p_clcb, GATT_SUCCESS, NULL); } /******************************************************************************* Loading Loading
system/stack/gatt/gatt_cl.cc +35 −34 Original line number Diff line number Diff line Loading @@ -79,10 +79,14 @@ uint16_t disc_type_to_uuid[GATT_DISC_MAX] = { ******************************************************************************/ void gatt_act_discovery(tGATT_CLCB* p_clcb) { uint8_t op_code = disc_type_to_att_opcode[p_clcb->op_subtype]; tGATT_CL_MSG cl_req; tGATT_STATUS st; if (p_clcb->s_handle <= p_clcb->e_handle && p_clcb->s_handle != 0) { if (p_clcb->s_handle > p_clcb->e_handle || p_clcb->s_handle == 0) { /* end of handle range */ gatt_end_operation(p_clcb, GATT_SUCCESS, NULL); return; } tGATT_CL_MSG cl_req; memset(&cl_req, 0, sizeof(tGATT_CL_MSG)); cl_req.browse.s_handle = p_clcb->s_handle; Loading Loading @@ -112,13 +116,10 @@ void gatt_act_discovery(tGATT_CLCB* p_clcb) { size); } st = attp_send_cl_msg(*p_clcb->p_tcb, p_clcb, op_code, &cl_req); tGATT_STATUS st = attp_send_cl_msg(*p_clcb->p_tcb, p_clcb, op_code, &cl_req); if (st != GATT_SUCCESS && st != GATT_CMD_STARTED) { gatt_end_operation(p_clcb, GATT_ERROR, NULL); } } else /* end of handle range */ gatt_end_operation(p_clcb, GATT_SUCCESS, NULL); } /******************************************************************************* Loading