mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 22:45:39 +00:00
A couple of more cleanups after free in opensslrsa_generate()
This commit is contained in:
@@ -1059,13 +1059,19 @@ opensslrsa_generate(dst_key_t *key, int exp, void (*callback)(int)) {
|
|||||||
|
|
||||||
err:
|
err:
|
||||||
#if USE_EVP
|
#if USE_EVP
|
||||||
if (pkey != NULL)
|
if (pkey != NULL) {
|
||||||
EVP_PKEY_free(pkey);
|
EVP_PKEY_free(pkey);
|
||||||
|
pkey = NULL;
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
if (e != NULL)
|
if (e != NULL) {
|
||||||
BN_free(e);
|
BN_free(e);
|
||||||
if (rsa != NULL)
|
e = NULL;
|
||||||
|
}
|
||||||
|
if (rsa != NULL) {
|
||||||
RSA_free(rsa);
|
RSA_free(rsa);
|
||||||
|
rsa = NULL;
|
||||||
|
}
|
||||||
if (cb != NULL) {
|
if (cb != NULL) {
|
||||||
BN_GENCB_free(cb);
|
BN_GENCB_free(cb);
|
||||||
cb = NULL;
|
cb = NULL;
|
||||||
|
Reference in New Issue
Block a user