]> git.ipfire.org Git - thirdparty/openssl.git/blobdiff - crypto/evp/evp_enc.c
Identify and move common internal libcrypto header files
[thirdparty/openssl.git] / crypto / evp / evp_enc.c
index 242874c5f646237ba15039280c97b3e8cfe669bb..125556ea6f4e070f0b6ac4cf46db8f8fcab2bdba 100644 (file)
@@ -57,7 +57,7 @@
  */
 
 #include <stdio.h>
-#include "cryptlib.h"
+#include "internal/cryptlib.h"
 #include <openssl/evp.h>
 #include <openssl/err.h>
 #include <openssl/rand.h>
@@ -165,6 +165,7 @@ int EVP_CipherInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher,
                 EVPerr(EVP_F_EVP_CIPHERINIT_EX, ERR_R_MALLOC_FAILURE);
                 return 0;
             }
+            memset(ctx->cipher_data, 0, ctx->cipher->ctx_size);
         } else {
             ctx->cipher_data = NULL;
         }