mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 06:25:31 +00:00
Remove blocks checking whether isc_mem_get() failed using the coccinelle
This commit is contained in:
@@ -625,8 +625,6 @@ openssleddsa_tofile(const dst_key_t *key, const char *directory) {
|
||||
if (key->key_alg == DST_ALG_ED25519) {
|
||||
len = DNS_KEY_ED25519SIZE;
|
||||
buf = isc_mem_get(key->mctx, len);
|
||||
if (buf == NULL)
|
||||
return (ISC_R_NOMEMORY);
|
||||
priv.elements[0].tag = TAG_EDDSA_PRIVATEKEY;
|
||||
priv.elements[0].length = len;
|
||||
ret = priv_ed25519_from_ossl(pkey, buf);
|
||||
@@ -638,8 +636,6 @@ openssleddsa_tofile(const dst_key_t *key, const char *directory) {
|
||||
} else {
|
||||
len = DNS_KEY_ED448SIZE;
|
||||
buf = isc_mem_get(key->mctx, len);
|
||||
if (buf == NULL)
|
||||
return (ISC_R_NOMEMORY);
|
||||
priv.elements[0].tag = TAG_EDDSA_PRIVATEKEY;
|
||||
priv.elements[0].length = len;
|
||||
ret = priv_ed448_from_ossl(pkey, buf);
|
||||
|
Reference in New Issue
Block a user