summaryrefslogtreecommitdiffstats
path: root/crypto/evp/evp_enc.c
diff options
context:
space:
mode:
authorDr. Stephen Henson <steve@openssl.org>2002-02-23 13:50:29 +0000
committerDr. Stephen Henson <steve@openssl.org>2002-02-23 13:50:29 +0000
commita3829cb720c235a93b6d1067555d7d113a8ba326 (patch)
treef92f854094add61d34390a9065fd0ccd5c13797d /crypto/evp/evp_enc.c
parente84be9b495f1672eac43642687bfa05491d53cff (diff)
Updates from stable branch.
Diffstat (limited to 'crypto/evp/evp_enc.c')
-rw-r--r--crypto/evp/evp_enc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/crypto/evp/evp_enc.c b/crypto/evp/evp_enc.c
index eb39539ca6..9c65a553d3 100644
--- a/crypto/evp/evp_enc.c
+++ b/crypto/evp/evp_enc.c
@@ -77,7 +77,8 @@ void EVP_CIPHER_CTX_init(EVP_CIPHER_CTX *ctx)
int EVP_CipherInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher,
const unsigned char *key, const unsigned char *iv, int enc)
{
- EVP_CIPHER_CTX_init(ctx);
+ if (cipher)
+ EVP_CIPHER_CTX_init(ctx);
return EVP_CipherInit_ex(ctx,cipher,NULL,key,iv,enc);
}