Fix Coverity CID:1453685 'unreachable code' in aes_xts code.
authorShane Lontis <shane.lontis@oracle.com>
Wed, 18 Sep 2019 05:20:30 +0000 (15:20 +1000)
committerShane Lontis <shane.lontis@oracle.com>
Wed, 18 Sep 2019 05:20:30 +0000 (15:20 +1000)
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Kurt Roeckx <kurt@roeckx.be>
(Merged from https://github.com/openssl/openssl/pull/9902)

providers/common/ciphers/cipher_aes_xts.c

index c85475442b404467fceb02149e04ff2ffb27448c..0d642368b39212f806650f99b0936ac611b1274d 100644 (file)
@@ -176,7 +176,6 @@ static int aes_xts_cipher(void *vctx, unsigned char *out, size_t *outl,
     else if (CRYPTO_xts128_encrypt(&ctx->xts, ctx->base.iv, in, out, inl,
                                    ctx->base.enc))
         return 0;
-    return 1;
 
     *outl = inl;
     return 1;
@@ -198,7 +197,6 @@ static int aes_xts_stream_update(void *vctx, unsigned char *out, size_t *outl,
         return 0;
     }
 
-    *outl = inl;
     return 1;
 }