diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2000-05-28 12:44:46 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2000-05-28 12:44:46 +0000 |
commit | 360370d9530d552078a453f7333faeab0039268f (patch) | |
tree | 8bc290cacd648726e273496e748e1f1f1eba6695 /crypto/evp/e_cbc_r2.c | |
parent | 1fab73ac856225762dae9ef738e792b5ccbd8a32 (diff) | |
download | openssl-360370d9530d552078a453f7333faeab0039268f.zip openssl-360370d9530d552078a453f7333faeab0039268f.tar.gz openssl-360370d9530d552078a453f7333faeab0039268f.tar.bz2 |
Third phase of EVP cipher overhaul.
Remove duplicated code in EVP.
Diffstat (limited to 'crypto/evp/e_cbc_r2.c')
-rw-r--r-- | crypto/evp/e_cbc_r2.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/crypto/evp/e_cbc_r2.c b/crypto/evp/e_cbc_r2.c index 5e91c9d..3552b67 100644 --- a/crypto/evp/e_cbc_r2.c +++ b/crypto/evp/e_cbc_r2.c @@ -139,11 +139,7 @@ EVP_CIPHER *EVP_rc2_40_cbc(void) static int rc2_cbc_init_key(EVP_CIPHER_CTX *ctx, unsigned char *key, unsigned char *iv, int enc) { - if (iv != NULL) - memcpy(&(ctx->oiv[0]),iv,8); - memcpy(&(ctx->iv[0]),&(ctx->oiv[0]),8); - if (key != NULL) - RC2_set_key(&(ctx->c.rc2_ks),EVP_CIPHER_CTX_key_length(ctx), + RC2_set_key(&(ctx->c.rc2_ks),EVP_CIPHER_CTX_key_length(ctx), key,EVP_CIPHER_key_length(ctx->cipher)*8); return 1; } |