nimble/ll: Add missing aux_data check
@@ -2635,12 +2635,14 @@ ble_ll_hci_send_ext_adv_report(uint8_t ptype, uint8_t *adva, uint8_t adva_type,
evt->evt_type |= (BLE_HCI_ADV_DATA_STATUS_INCOMPLETE);
} else {
evt->evt_type |= (BLE_HCI_ADV_DATA_STATUS_TRUNCATED);
- BLE_LL_AUX_SET_FLAG(aux_data, BLE_LL_AUX_TRUNCATED_SENT);
rc = -1;
+ if (aux_data) {
+ BLE_LL_AUX_SET_FLAG(aux_data, BLE_LL_AUX_TRUNCATED_SENT);
if (!BLE_LL_AUX_CHECK_FLAG(aux_data, BLE_LL_SENT_EVENT_TO_HOST)) {
ble_hci_trans_buf_free((uint8_t *)evt);
goto done;
}
+ }
}
} else if (aux_data) {
