static void bta_gattc_cmpl_sendmsg(UINT16 conn_id, tGATTC_OPTYPE op,
tBTA_GATT_STATUS status,
tGATT_CL_COMPLETE *p_data);
+static void bta_gattc_pop_command_to_send(tBTA_GATTC_CLCB *p_clcb);
static void bta_gattc_deregister_cmpl(tBTA_GATTC_RCB *p_clreg);
static void bta_gattc_enc_cmpl_cback(tGATT_IF gattc_if, BD_ADDR bda);
/* Dequeue the data, if it was enqueued */
if (p_clcb->p_q_cmd == p_data) {
p_clcb->p_q_cmd = NULL;
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
- bta_gattc_pop_command_to_send(p_clcb);
+ bta_gattc_pop_command_to_send(p_clcb);
}
bta_gattc_cmpl_sendmsg(p_clcb->bta_conn_id, GATTC_OPTYPE_CONFIG, status, NULL);
/* Dequeue the data, if it was enqueued */
if (p_clcb->p_q_cmd == p_data) {
p_clcb->p_q_cmd = NULL;
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
bta_gattc_pop_command_to_send(p_clcb);
}
/* Dequeue the data, if it was enqueued */
if (p_clcb->p_q_cmd == p_data) {
p_clcb->p_q_cmd = NULL;
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
- bta_gattc_pop_command_to_send(p_clcb);
+ bta_gattc_pop_command_to_send(p_clcb);
}
bta_gattc_cmpl_sendmsg(p_clcb->bta_conn_id, GATTC_OPTYPE_READ, status, NULL);
/* Dequeue the data, if it was enqueued */
if (p_clcb->p_q_cmd == p_data) {
p_clcb->p_q_cmd = NULL;
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
bta_gattc_pop_command_to_send(p_clcb);
}
/* Dequeue the data, if it was enqueued */
if (p_clcb->p_q_cmd == p_data) {
p_clcb->p_q_cmd = NULL;
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
bta_gattc_pop_command_to_send(p_clcb);
}
cb_data.read.conn_id = p_clcb->bta_conn_id;
//free the command data store in the queue.
bta_gattc_free_command_data(p_clcb);
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
bta_gattc_pop_command_to_send(p_clcb);
/* read complete, callback */
( *p_clcb->p_rcb->p_cback)(event, (tBTA_GATTC *)&cb_data);
}
//free the command data store in the queue.
bta_gattc_free_command_data(p_clcb);
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
bta_gattc_pop_command_to_send(p_clcb);
cb_data.write.conn_id = p_clcb->bta_conn_id;
/* write complete, callback */
tBTA_GATTC cb_data;
//free the command data store in the queue.
bta_gattc_free_command_data(p_clcb);
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
bta_gattc_pop_command_to_send(p_clcb);
p_clcb->status = BTA_GATT_OK;
tBTA_GATTC cb_data;
//free the command data store in the queue.
bta_gattc_free_command_data(p_clcb);
- /* Check if there has command pending in the command queue or not,
- if there has command pending in the command queue, sent it to the state machine to decision
- should be sent it to the remote device or not. */
bta_gattc_pop_command_to_send(p_clcb);
if (p_data->p_cmpl && p_data->status == BTA_GATT_OK) {
** Function bta_gattc_pop_command_to_send
**
** Description dequeue a command into control block.
+** Check if there has command pending in the command queue or not,
+** if there has command pending in the command queue, sent it to the state machine to decision
+** should be sent it to the remote device or not.
**
** Returns None.
**
*******************************************************************************/
-void bta_gattc_pop_command_to_send(tBTA_GATTC_CLCB *p_clcb)
+static void bta_gattc_pop_command_to_send(tBTA_GATTC_CLCB *p_clcb)
{
if (!list_is_empty(p_clcb->p_cmd_list)) {
list_node_t *node = list_begin(p_clcb->p_cmd_list);