BLE: Return error when security deascalation is requested.

pull/6188/head
Vincent Coubard 2018-03-01 14:44:18 +00:00
parent 7e2f5ee008
commit e29ea95fc9
1 changed files with 1 additions and 1 deletions

View File

@ -383,7 +383,7 @@ ble_error_t GenericSecurityManager::setLinkEncryption(
if (encryption == link_encryption_t::NOT_ENCRYPTED) {
return _pal.disable_encryption(connection);
return BLE_ERROR_INVALID_STATE;
} else if (encryption == link_encryption_t::ENCRYPTED) {