Fix mem leak in DSA

This commit is contained in:
Tesfa Mael
2020-01-15 16:03:42 -08:00
parent 6b4551c012
commit fbf91f7397

View File

@ -4622,6 +4622,7 @@ int DsaPrivateKeyDecode(const byte* input, word32* inOutIdx, DsaKey* key,
GetInt(&key->g, input, inOutIdx, inSz) < 0 ||
GetOctetString(input, inOutIdx, &length, inSz) < 0 ||
GetInt(&key->y, input, inOutIdx, inSz) < 0) {
wc_FreeDsaKey(key);
ret = ASN_PARSE_E;
}
if (ret == ASN_PARSE_E) {