mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-04-24 06:02:43 +00:00
clear packet buffer in mock hci for security test
This commit is contained in:
parent
d6f5bc2d39
commit
e24b2953c8
@ -33,10 +33,11 @@ uint8_t * mock_packet_buffer(void){
|
|||||||
|
|
||||||
void mock_clear_packet_buffer(void){
|
void mock_clear_packet_buffer(void){
|
||||||
packet_buffer_len = 0;
|
packet_buffer_len = 0;
|
||||||
|
memset(packet_buffer, 0, sizeof(packet_buffer));
|
||||||
}
|
}
|
||||||
|
|
||||||
static void dump_packet(int packet_type, uint8_t * buffer, uint16_t size){
|
static void dump_packet(int packet_type, uint8_t * buffer, uint16_t size){
|
||||||
#if 0
|
#if 1
|
||||||
static int packet_counter = 1;
|
static int packet_counter = 1;
|
||||||
char var_name[80];
|
char var_name[80];
|
||||||
sprintf(var_name, "test_%s_packet_%02u", packet_type == HCI_COMMAND_DATA_PACKET ? "command" : "acl", packet_counter);
|
sprintf(var_name, "test_%s_packet_%02u", packet_type == HCI_COMMAND_DATA_PACKET ? "command" : "acl", packet_counter);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user