Feedback changes implemented

This commit is contained in:
Kaleb Himes
2019-06-03 15:13:02 -06:00
committed by GitHub
parent 80dd6cc143
commit 290663f8b2

View File

@ -198,8 +198,10 @@ int wc_PBKDF2(byte* output, const byte* passwd, int pLen, const byte* salt,
if (buffer == NULL)
return MEMORY_E;
hmac = (Hmac*)XMALLOC(sizeof(Hmac), NULL, DYNAMIC_TYPE_HMAC);
if (hmac == NULL)
if (hmac == NULL) {
XFREE(buffer, NULL, DYNAMIC_TYPE_TMP_BUFFER);
return MEMORY_E;
}
#endif
ret = wc_HmacInit(hmac, NULL, INVALID_DEVID);