Fix memory leak on error path in esp_ds_start_sign

This commit is contained in:
Alex Henrie 2021-07-20 13:52:53 -06:00 committed by Aditya Patwardhan
parent 30e9242f90
commit f88a2f10c2

View File

@ -129,6 +129,7 @@ esp_err_t esp_ds_start_sign(const void *message,
if (result == ETS_DS_INVALID_KEY) {
ds_disable_release();
free(context);
return ESP_ERR_HW_CRYPTO_DS_INVALID_KEY;
}