diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib/libcrypto/evp/cipher_method_lib.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/lib/libcrypto/evp/cipher_method_lib.c b/src/lib/libcrypto/evp/cipher_method_lib.c index dc37050408..55dc6b788c 100644 --- a/src/lib/libcrypto/evp/cipher_method_lib.c +++ b/src/lib/libcrypto/evp/cipher_method_lib.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: cipher_method_lib.c,v 1.7 2023/03/01 11:25:25 tb Exp $ */ | 1 | /* $OpenBSD: cipher_method_lib.c,v 1.8 2023/03/01 11:27:37 tb Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Written by Richard Levitte (levitte@openssl.org) for the OpenSSL project | 3 | * Written by Richard Levitte (levitte@openssl.org) for the OpenSSL project |
| 4 | * 2015. | 4 | * 2015. |
| @@ -83,8 +83,7 @@ EVP_CIPHER_meth_dup(const EVP_CIPHER *cipher) | |||
| 83 | { | 83 | { |
| 84 | EVP_CIPHER *copy; | 84 | EVP_CIPHER *copy; |
| 85 | 85 | ||
| 86 | if ((copy = EVP_CIPHER_meth_new(cipher->nid, cipher->block_size, | 86 | if ((copy = calloc(1, sizeof(*copy))) == NULL) |
| 87 | cipher->key_len)) == NULL) | ||
| 88 | return NULL; | 87 | return NULL; |
| 89 | 88 | ||
| 90 | *copy = *cipher; | 89 | *copy = *cipher; |
