DecodeNameConstraints (ASN Template): free ASNGetData

This commit is contained in:
Sean Parkinson
2022-03-14 09:14:19 +10:00
parent fb0c9b2a66
commit 20562b3f78

View File

@ -16198,8 +16198,8 @@ static int DecodeNameConstraints(const byte* input, int sz, DecodedCert* cert)
if (ret == 0) {
/* Parse NameConstraints. */
ret = GetASN_Items(nameConstraintsASN, dataASN, nameConstraintsASN_Length,
1, input, &idx, sz);
ret = GetASN_Items(nameConstraintsASN, dataASN,
nameConstraintsASN_Length, 1, input, &idx, sz);
}
if (ret == 0) {
/* If there was a permittedSubtrees then parse it. */
@ -16220,6 +16220,8 @@ static int DecodeNameConstraints(const byte* input, int sz, DecodedCert* cert)
}
}
FREE_ASNGETDATA(dataASN, cert->heap);
return ret;
#endif /* WOLFSSL_ASN_TEMPLATE */
}