wolfssl: Properly handle failure to initialize SHAKE_256

This commit is contained in:
Tobias Brunner
2021-05-06 11:47:38 +02:00
parent 2f650e085b
commit 9535c3f778
@@ -143,6 +143,7 @@ xof_t *wolfssl_xof_create(ext_out_function_t algorithm)
if (wc_InitShake256(&this->shake, NULL, 0) != 0) if (wc_InitShake256(&this->shake, NULL, 0) != 0)
{ {
free(this); free(this);
return NULL;
} }
return &this->public; return &this->public;