From 252bd3eb711652c9964b3c8ea24d337d542f3773 Mon Sep 17 00:00:00 2001 From: Zhang Hai Peng Date: Tue, 30 Dec 2025 11:53:50 +0800 Subject: [PATCH] fix(ble/bluedroid): Fix array index in set_periodic_adv_subevt_data (cherry picked from commit 12225c457c5c5bed8a8fbcddf3020de79083070f) Co-authored-by: zhanghaipeng --- components/bt/host/bluedroid/stack/hcic/hciblecmds.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/bt/host/bluedroid/stack/hcic/hciblecmds.c b/components/bt/host/bluedroid/stack/hcic/hciblecmds.c index b6f48f5642f..fef574fd6ab 100644 --- a/components/bt/host/bluedroid/stack/hcic/hciblecmds.c +++ b/components/bt/host/bluedroid/stack/hcic/hciblecmds.c @@ -2994,7 +2994,7 @@ UINT8 btsnd_hcic_ble_set_periodic_adv_subevt_data(UINT8 adv_handle, UINT8 num_su esp_log_buffer_hex_internal("data", subevent_params[i].data, subevent_params[i].subevent_data_len, ESP_LOG_DEBUG); } - param_len += (4 + subevent_params->subevent_data_len); + param_len += (4 + subevent_params[i].subevent_data_len); } HCIC_BLE_CMD_CREATED(p, pp, param_len);