Fix parameter to BLEDevice::updatePeerDevice (#4133)

::addPeerDevice and ::removePeerDevice are called with m_appId, so should ::updatePeerDevice as all use the same parameter for the underlying map's key.
This commit is contained in:
buxtronix 2020-11-03 05:20:16 +11:00 committed by GitHub
parent 704b71dabe
commit 9f7ff009c6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -237,7 +237,7 @@ void BLEClient::gattClientEventHandler(
case ESP_GATTC_CONNECT_EVT: {
if (evtParam->connect.conn_id != getConnId()) break;
BLEDevice::updatePeerDevice(this, true, m_gattc_if);
BLEDevice::updatePeerDevice(this, true, m_appId);
esp_err_t errRc = esp_ble_gattc_send_mtu_req(gattc_if, evtParam->connect.conn_id);
if (errRc != ESP_OK) {
log_e("esp_ble_gattc_send_mtu_req: rc=%d %s", errRc, GeneralUtils::errorToString(errRc));