Merge branch 'bugfix/btdm_reconnect_con_params_update_reject_in_smp' into 'master'
Component/bt: update con params is rejected in smp when reconnection See merge request idf/esp-idf!2318
This commit is contained in:
commit
9e5318b584
3 changed files with 10 additions and 2 deletions
|
@ -331,7 +331,9 @@ void bta_gattc_co_cache_addr_init(void)
|
|||
cache_env.addr_fp = fp;
|
||||
// Read previously saved blob if available
|
||||
if ((err_code = nvs_get_blob(fp, cache_key, p_buf, &length)) != ESP_OK) {
|
||||
APPL_TRACE_ERROR("%s, Line = %d, nvs flash get blob data fail, err_code = %x", __func__, __LINE__, err_code);
|
||||
if(err_code != ESP_ERR_NVS_NOT_FOUND) {
|
||||
APPL_TRACE_ERROR("%s, Line = %d, nvs flash get blob data fail, err_code = 0x%x", __func__, __LINE__, err_code);
|
||||
}
|
||||
osi_free(p_buf);
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -4018,6 +4018,7 @@ void btm_sec_encrypt_change (UINT16 handle, UINT8 status, UINT8 encr_enable)
|
|||
#if BLE_INCLUDED == TRUE && SMP_INCLUDED == TRUE
|
||||
tACL_CONN *p_acl = NULL;
|
||||
UINT8 acl_idx = btm_handle_to_acl_index(handle);
|
||||
tGATT_TCB *p_tcb = NULL;
|
||||
#endif
|
||||
BTM_TRACE_EVENT ("Security Manager: encrypt_change status:%d State:%d, encr_enable = %d\n",
|
||||
status, (p_dev_rec) ? p_dev_rec->sec_state : 0, encr_enable);
|
||||
|
@ -4045,6 +4046,11 @@ void btm_sec_encrypt_change (UINT16 handle, UINT8 status, UINT8 encr_enable)
|
|||
p_dev_rec->sec_flags |= BTM_SEC_16_DIGIT_PIN_AUTHED;
|
||||
}
|
||||
} else {
|
||||
#if BLE_INCLUDED == TRUE && SMP_INCLUDED == TRUE
|
||||
if ((p_tcb = gatt_find_tcb_by_addr(p_dev_rec->ble.pseudo_addr, BT_TRANSPORT_LE)) == NULL) {
|
||||
//do nothing
|
||||
} else
|
||||
#endif
|
||||
p_dev_rec->sec_flags |= (BTM_SEC_LE_AUTHENTICATED | BTM_SEC_LE_ENCRYPTED);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 34b64038d090fa172d9757e2fce293ff26e0a08c
|
||||
Subproject commit a3e98f83144ee46c6ec9b53b1c838bcefdf26e97
|
Loading…
Reference in a new issue