Skip to content

Commit

Permalink
use original macro
Browse files Browse the repository at this point in the history
  • Loading branch information
jouho committed Jul 3, 2024
1 parent a37c677 commit 84132f4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions crypto/s2n_cipher.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ int s2n_session_key_alloc(struct s2n_session_key *key)
{
POSIX_ENSURE_EQ(key->evp_cipher_ctx, NULL);
POSIX_ENSURE_REF(key->evp_cipher_ctx = EVP_CIPHER_CTX_new());
#if defined(S2N_LIBCRYPTO_SUPPORTS_EVP_AEAD_TLS)
#if defined(S2N_CIPHER_AEAD_API_AVAILABLE)
POSIX_ENSURE_EQ(key->evp_aead_ctx, NULL);
key->evp_aead_ctx = OPENSSL_malloc(sizeof(EVP_AEAD_CTX));
if (key->evp_aead_ctx == NULL) {
Expand All @@ -44,7 +44,7 @@ int s2n_session_key_free(struct s2n_session_key *key)
EVP_CIPHER_CTX_free(key->evp_cipher_ctx);
key->evp_cipher_ctx = NULL;
}
#if defined(S2N_LIBCRYPTO_SUPPORTS_EVP_AEAD_TLS)
#if defined(S2N_CIPHER_AEAD_API_AVAILABLE)
if (key->evp_aead_ctx != NULL) {
EVP_AEAD_CTX_free(key->evp_aead_ctx);
key->evp_aead_ctx = NULL;
Expand Down

0 comments on commit 84132f4

Please sign in to comment.