Merge branch 'bugfix/a2dp_source_not_stop_discovery_correctly' into 'master'

bugfix/avoid wrongly restart discovery in a2dp_source

See merge request espressif/esp-idf!18536
This commit is contained in:
Jiang Jiang Jian 2022-06-29 11:24:00 +08:00
commit 04830a3284

View File

@ -213,7 +213,9 @@ static void bt_app_gap_cb(esp_bt_gap_cb_event_t event, esp_bt_gap_cb_param_t *pa
switch (event) { switch (event) {
/* when device discovered a result, this event comes */ /* when device discovered a result, this event comes */
case ESP_BT_GAP_DISC_RES_EVT: { case ESP_BT_GAP_DISC_RES_EVT: {
filter_inquiry_scan_result(param); if (s_a2d_state == APP_AV_STATE_DISCOVERING) {
filter_inquiry_scan_result(param);
}
break; break;
} }
/* when discovery state changed, this event comes */ /* when discovery state changed, this event comes */