ccm: Destroy IV generator on crypter creation failure
Closes strongswan/strongswan#343.
This commit is contained in:
committed by
Tobias Brunner
parent
a82f13e7ce
commit
d654117c66
@@ -417,6 +417,7 @@ ccm_aead_t *ccm_aead_create(encryption_algorithm_t algo,
|
|||||||
|
|
||||||
if (!this->crypter)
|
if (!this->crypter)
|
||||||
{
|
{
|
||||||
|
this->iv_gen->destroy(this->iv_gen);
|
||||||
free(this);
|
free(this);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user