mirror of
https://github.com/esphome/esphome.git
synced 2025-04-13 06:10:30 +01:00
Fix end_of_scan_ not being called while disconnecting (#8328)
This commit is contained in:
parent
3048f303c5
commit
28f283d545
@ -176,9 +176,9 @@ void ESP32BLETracker::loop() {
|
||||
https://github.com/espressif/esp-idf/issues/6688
|
||||
|
||||
*/
|
||||
if (!connecting && !disconnecting && xSemaphoreTake(this->scan_end_lock_, 0L)) {
|
||||
if (!connecting && xSemaphoreTake(this->scan_end_lock_, 0L)) {
|
||||
if (this->scan_continuous_) {
|
||||
if (!promote_to_connecting && !this->scan_start_failed_ && !this->scan_set_param_failed_) {
|
||||
if (!disconnecting && !promote_to_connecting && !this->scan_start_failed_ && !this->scan_set_param_failed_) {
|
||||
this->start_scan_(false);
|
||||
} else {
|
||||
// We didn't start the scan, so we need to release the lock
|
||||
|
Loading…
x
Reference in New Issue
Block a user