Commit a7f9e0a4 authored by Matt Caswell's avatar Matt Caswell
Browse files

Remove an unneccessary check of cipher



Due to short-circuiting we only need to check "cipher" for NULL once.

PR#699

Reviewed-by: default avatarRichard Levitte <levitte@openssl.org>
parent 49445f21
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -120,7 +120,7 @@ int EVP_CipherInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher,
     * reinitialisation, when it may all be unnecessary.
     */
    if (ctx->engine && ctx->cipher
        && (!cipher || (cipher && (cipher->nid == ctx->cipher->nid))))
        && (cipher == NULL || cipher->nid == ctx->cipher->nid))
        goto skip_to_init;
#endif
    if (cipher) {