mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-01-18 10:22:54 +00:00
auto-pts: remove timer before adding them again
This commit is contained in:
parent
0ec8b67496
commit
a92b1593b3
@ -755,6 +755,7 @@ static void btp_gap_handler(uint8_t opcode, uint8_t controller_index, uint16_t l
|
||||
}
|
||||
if (flags & BTP_GAP_DISCOVERY_FLAG_LIMITED){
|
||||
// set timer
|
||||
btstack_run_loop_remove_timer(&gap_limited_discovery_timer);
|
||||
btstack_run_loop_set_timer_handler(&gap_limited_discovery_timer, gap_limited_discovery_timeout_handler);
|
||||
btstack_run_loop_set_timer(&gap_limited_discovery_timer, LIM_DISC_SCAN_MIN_MS);
|
||||
btstack_run_loop_add_timer(&gap_limited_discovery_timer);
|
||||
@ -794,6 +795,7 @@ static void btp_gap_handler(uint8_t opcode, uint8_t controller_index, uint16_t l
|
||||
// schedule response
|
||||
gap_send_connect_response = true;
|
||||
#if 1
|
||||
btstack_run_loop_remove_timer(&gap_connection_timer);
|
||||
btstack_run_loop_set_timer_handler(&gap_connection_timer, &gap_connect_timeout_handler);
|
||||
btstack_run_loop_set_timer(&gap_connection_timer, GAP_CONNECT_TIMEOUT_MS);
|
||||
btstack_run_loop_add_timer(&gap_connection_timer);
|
||||
|
Loading…
Reference in New Issue
Block a user