Loading system/btif/src/btif_ble_scanner.cc +15 −9 Original line number Diff line number Diff line Loading @@ -83,6 +83,7 @@ struct equal_to<bt_bdaddr_t> { namespace { // all access to this variable should be done on the jni thread std::unordered_set<bt_bdaddr_t> p_dev_cb; void btif_gattc_add_remote_bdaddr(BD_ADDR p_bda, uint8_t addr_type) { Loading Loading @@ -258,8 +259,11 @@ class BleScannerInterfaceImpl : public BleScannerInterface { } void Scan(bool start) override { do_in_jni_thread(Bind( [](bool start) { if (!start) { do_in_bta_thread(FROM_HERE, Bind(&BTA_DmBleObserve, false, 0, nullptr)); do_in_bta_thread(FROM_HERE, Bind(&BTA_DmBleObserve, false, 0, nullptr)); return; } Loading @@ -267,6 +271,8 @@ class BleScannerInterfaceImpl : public BleScannerInterface { do_in_bta_thread(FROM_HERE, Bind(&BTA_DmBleObserve, true, 0, (tBTA_DM_SEARCH_CBACK*)bta_scan_results_cb)); }, start)); } void ScanFilterParamSetup( Loading Loading
system/btif/src/btif_ble_scanner.cc +15 −9 Original line number Diff line number Diff line Loading @@ -83,6 +83,7 @@ struct equal_to<bt_bdaddr_t> { namespace { // all access to this variable should be done on the jni thread std::unordered_set<bt_bdaddr_t> p_dev_cb; void btif_gattc_add_remote_bdaddr(BD_ADDR p_bda, uint8_t addr_type) { Loading Loading @@ -258,8 +259,11 @@ class BleScannerInterfaceImpl : public BleScannerInterface { } void Scan(bool start) override { do_in_jni_thread(Bind( [](bool start) { if (!start) { do_in_bta_thread(FROM_HERE, Bind(&BTA_DmBleObserve, false, 0, nullptr)); do_in_bta_thread(FROM_HERE, Bind(&BTA_DmBleObserve, false, 0, nullptr)); return; } Loading @@ -267,6 +271,8 @@ class BleScannerInterfaceImpl : public BleScannerInterface { do_in_bta_thread(FROM_HERE, Bind(&BTA_DmBleObserve, true, 0, (tBTA_DM_SEARCH_CBACK*)bta_scan_results_cb)); }, start)); } void ScanFilterParamSetup( Loading