diff options
author | beck <> | 2014-05-22 21:56:02 +0000 |
---|---|---|
committer | beck <> | 2014-05-22 21:56:02 +0000 |
commit | ffb0c4aec230128ccb49ed44ab8bbaa5558018a0 (patch) | |
tree | ad01380ef0f2b2de9b4b3d5c76c4e3dcd7fdccdd /src/lib/libcrypto/evp/e_chacha20poly1305.c | |
parent | c34fac2dfaf2da90889ed845a5139c916868eea2 (diff) | |
download | openbsd-ffb0c4aec230128ccb49ed44ab8bbaa5558018a0.tar.gz openbsd-ffb0c4aec230128ccb49ed44ab8bbaa5558018a0.tar.bz2 openbsd-ffb0c4aec230128ccb49ed44ab8bbaa5558018a0.zip |
Convert OPENSSL_malloc stuff back to intrinsics, a few were missed
as new stuff was brought in.
ok miod@
Diffstat (limited to '')
-rw-r--r-- | src/lib/libcrypto/evp/e_chacha20poly1305.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/libcrypto/evp/e_chacha20poly1305.c b/src/lib/libcrypto/evp/e_chacha20poly1305.c index 75ff7f209c..7e32668b7f 100644 --- a/src/lib/libcrypto/evp/e_chacha20poly1305.c +++ b/src/lib/libcrypto/evp/e_chacha20poly1305.c | |||
@@ -85,7 +85,7 @@ aead_chacha20_poly1305_init(EVP_AEAD_CTX *ctx, const unsigned char *key, | |||
85 | if (key_len != sizeof(c20_ctx->key)) | 85 | if (key_len != sizeof(c20_ctx->key)) |
86 | return 0; /* internal error - EVP_AEAD_CTX_init should catch this. */ | 86 | return 0; /* internal error - EVP_AEAD_CTX_init should catch this. */ |
87 | 87 | ||
88 | c20_ctx = OPENSSL_malloc(sizeof(struct aead_chacha20_poly1305_ctx)); | 88 | c20_ctx = malloc(sizeof(struct aead_chacha20_poly1305_ctx)); |
89 | if (c20_ctx == NULL) | 89 | if (c20_ctx == NULL) |
90 | return 0; | 90 | return 0; |
91 | 91 | ||
@@ -101,7 +101,7 @@ aead_chacha20_poly1305_cleanup(EVP_AEAD_CTX *ctx) | |||
101 | { | 101 | { |
102 | struct aead_chacha20_poly1305_ctx *c20_ctx = ctx->aead_state; | 102 | struct aead_chacha20_poly1305_ctx *c20_ctx = ctx->aead_state; |
103 | OPENSSL_cleanse(c20_ctx->key, sizeof(c20_ctx->key)); | 103 | OPENSSL_cleanse(c20_ctx->key, sizeof(c20_ctx->key)); |
104 | OPENSSL_free(c20_ctx); | 104 | free(c20_ctx); |
105 | } | 105 | } |
106 | 106 | ||
107 | static void | 107 | static void |