File tree Expand file tree Collapse file tree 1 file changed +2
-11
lines changed
features/FEATURE_BLE/source/generic Expand file tree Collapse file tree 1 file changed +2
-11
lines changed Original file line number Diff line number Diff line change @@ -2387,9 +2387,6 @@ ble_error_t GenericGap::stopAdvertising(advertising_handle_t handle)
2387
2387
ble_error_t status;
2388
2388
2389
2389
if (is_extended_advertising_available ()) {
2390
-
2391
- _active_sets.clear (handle);
2392
-
2393
2390
status = _pal_gap.extended_advertising_enable (
2394
2391
/* enable ? */ false ,
2395
2392
/* number of advertising sets */ 1 ,
@@ -2399,26 +2396,24 @@ ble_error_t GenericGap::stopAdvertising(advertising_handle_t handle)
2399
2396
);
2400
2397
2401
2398
if (status) {
2402
- _active_sets.set (handle);
2403
2399
return status;
2404
2400
}
2405
2401
} else {
2406
2402
if (handle != LEGACY_ADVERTISING_HANDLE) {
2407
2403
return BLE_ERROR_INVALID_PARAM;
2408
2404
}
2409
2405
2410
- _active_sets.clear (handle);
2411
-
2412
2406
status = _pal_gap.advertising_enable (false );
2413
2407
2414
2408
if (status) {
2415
- _active_sets.set (handle);
2416
2409
return status;
2417
2410
}
2418
2411
2419
2412
_advertising_timeout.detach ();
2420
2413
}
2421
2414
2415
+ _active_sets.clear (handle);
2416
+
2422
2417
return status;
2423
2418
}
2424
2419
@@ -2746,10 +2741,6 @@ void GenericGap::on_advertising_set_terminated(
2746
2741
uint8_t number_of_completed_extended_advertising_events
2747
2742
)
2748
2743
{
2749
- if (!_active_sets.get (advertising_handle)) {
2750
- return ;
2751
- }
2752
-
2753
2744
_active_sets.clear (advertising_handle);
2754
2745
2755
2746
if (!_eventHandler) {
You can’t perform that action at this time.
0 commit comments