Third phase of EVP cipher overhaul.
[openssl.git] / crypto / evp / e_ofb_c.c
index b84a42d7f5104e56478ae8cdbd03d52dd722162a..20c843c22f86c758d628c15e193122dd9b4917b6 100644 (file)
@@ -90,13 +90,7 @@ EVP_CIPHER *EVP_cast5_ofb(void)
 static int cast_ofb_init_key(EVP_CIPHER_CTX *ctx, unsigned char *key,
             unsigned char *iv, int enc)
        {
-       ctx->num=0;
-
-       if (iv != NULL)
-               memcpy(&(ctx->oiv[0]),iv,8);
-       memcpy(&(ctx->iv[0]),&(ctx->oiv[0]),8);
-       if (key != NULL)
-               CAST_set_key(&(ctx->c.cast_ks),EVP_CIPHER_CTX_key_length(ctx),key);
+       CAST_set_key(&(ctx->c.cast_ks),EVP_CIPHER_CTX_key_length(ctx),key);
        return 1;
        }