Each pointer that was freed by one of the following functions should
be reset to NULL:
- config_free()
- data_dispatcher_free()
- fixed_queue_free()
- list_free()
Bug:
29421693
Change-Id: Ie55a04ed986393994564edcf872d7413b0767a85
(cherry picked from commit
8cbc291080730cd7d04990a8fc0e11249b06aa08)
}
}
list_free(soc_queue);
+ soc_queue = NULL;
return (int)result;
}
if (rfc_slots[i].id)
cleanup_rfc_slot(&rfc_slots[i]);
list_free(rfc_slots[i].incoming_queue);
+ rfc_slots[i].incoming_queue = NULL;
}
pthread_mutex_unlock(&slot_lock);
}
fixed_queue_free(packet_queue, buffer_allocator->free);
packet_queue = NULL;
list_free(commands_pending_response);
+ commands_pending_response = NULL;
pthread_mutex_destroy(&commands_pending_response_lock);
interface.do_postload = NULL;
data_dispatcher_free(interface.event_dispatcher);
+ interface.event_dispatcher = NULL;
interface.set_data_queue = NULL;
interface.transmit_command = NULL;
static future_t *clean_up() {
config_free(config);
+ config = NULL;
return future_new_immediate(FUTURE_SUCCESS);
}
gatt_free_pending_ind(p_tcb);
gatt_free_pending_enc_queue(p_tcb);
fixed_queue_free(p_tcb->sr_cmd.multi_rsp_q, NULL);
+ p_tcb->sr_cmd.multi_rsp_q = NULL;
for (i = 0; i < GATT_MAX_APPS; i ++)
{
void l2c_free(void) {
list_free(l2cb.rcv_pending_q);
+ l2cb.rcv_pending_q = NULL;
}
void l2c_receive_hold_timer_timeout(UNUSED_ATTR void *data)
osi_free(p_buf);
}
fixed_queue_free(p_lcb->le_sec_pending_q, NULL);
+ p_lcb->le_sec_pending_q = NULL;
}
}
rfc_port_timer_stop (p_port);
fixed_queue_free(p_port->tx.queue, NULL);
+ p_port->tx.queue = NULL;
fixed_queue_free(p_port->rx.queue, NULL);
+ p_port->rx.queue = NULL;
if (p_port->keep_port_handle)
{